Version Description
Download this release
Release Info
Developer | ModernTribe |
Plugin | The Events Calendar |
Version | 4.6.15 |
Comparing to | |
See all releases |
Code changes from version 4.6.14.1 to 4.6.15
- common/lang/tribe-common.pot +1369 -1155
- common/readme.txt +7 -0
- common/src/Tribe/Context.php +1 -1
- common/src/Tribe/Date_Utils.php +1 -0
- common/src/Tribe/Db.php +38 -0
- common/src/Tribe/JSON_LD/Abstract.php +4 -4
- common/src/Tribe/Languages/Locations.php +2 -2
- common/src/Tribe/Main.php +6 -14
- common/src/Tribe/Meta/Chunker.php +2 -4
- common/src/Tribe/Process/Handler.php +15 -14
- common/src/Tribe/Process/Post_Thumbnail_Setter.php +5 -5
- common/src/Tribe/Process/Queue.php +451 -0
- common/src/Tribe/Service_Providers/Processes.php +80 -11
- common/src/Tribe/Timezones.php +136 -121
- common/src/admin-views/tribe-options-help.php +3 -3
- common/src/functions/template-tags/date.php +1 -1
- common/src/resources/css/datatables.css +5 -5
- common/src/resources/css/datatables.min.css +1 -1
- common/src/resources/postcss/datatables.pcss +5 -5
- common/tribe-common.php +1 -1
- common/vendor/datatables/{media → DataTables}/images/sort_asc.png +0 -0
- common/vendor/datatables/{media → DataTables}/images/sort_asc_disabled.png +0 -0
- common/vendor/datatables/{media → DataTables}/images/sort_both.png +0 -0
- common/vendor/datatables/{media → DataTables}/images/sort_desc.png +0 -0
- common/vendor/datatables/{media → DataTables}/images/sort_desc_disabled.png +0 -0
- common/vendor/datatables/datatables.css +1220 -0
- common/vendor/datatables/{media/js/jquery.dataTables.js → datatables.js} +12847 -337
- common/vendor/datatables/datatables.min.css +136 -0
- common/vendor/datatables/datatables.min.js +466 -0
- common/vendor/datatables/extensions/FixedHeader/css/fixedHeader.dataTables.css +0 -19
- common/vendor/datatables/extensions/FixedHeader/css/fixedHeader.dataTables.min.css +0 -1
- common/vendor/datatables/extensions/FixedHeader/js/dataTables.fixedHeader.js +0 -672
- common/vendor/datatables/extensions/FixedHeader/js/dataTables.fixedHeader.min.js +0 -17
- common/vendor/datatables/extensions/Responsive/css/responsive.dataTables.css +0 -178
- common/vendor/datatables/extensions/Responsive/css/responsive.dataTables.min.css +0 -1
- common/vendor/datatables/extensions/Responsive/js/dataTables.responsive.js +0 -1232
- common/vendor/datatables/extensions/Responsive/js/dataTables.responsive.min.js +0 -26
- common/vendor/datatables/extensions/Scroller/css/scroller.dataTables.css +0 -20
- common/vendor/datatables/extensions/Scroller/css/scroller.dataTables.min.css +0 -1
- common/vendor/datatables/extensions/Scroller/js/dataTables.scroller.js +0 -1349
- common/vendor/datatables/extensions/Scroller/js/dataTables.scroller.min.js +0 -27
- common/vendor/datatables/extensions/Select/css/select.dataTables.css +0 -100
- common/vendor/datatables/extensions/Select/css/select.dataTables.min.css +0 -1
- common/vendor/datatables/extensions/Select/js/dataTables.select.js +0 -1109
- common/vendor/datatables/extensions/Select/js/dataTables.select.min.js +0 -26
- common/vendor/datatables/media/css/jquery.dataTables.css +0 -452
- common/vendor/datatables/media/css/jquery.dataTables.min.css +0 -1
- common/vendor/datatables/media/css/jquery.dataTables_themeroller.css +0 -237
common/lang/tribe-common.pot
CHANGED
@@ -1,2272 +1,2486 @@
|
|
1 |
-
# Copyright (C) 2018 Tribe
|
2 |
-
# This file is distributed under the same license as the Tribe Common
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: Tribe Common 4.7.
|
|
|
|
|
6 |
"MIME-Version: 1.0\n"
|
7 |
"Content-Type: text/plain; charset=UTF-8\n"
|
8 |
"Content-Transfer-Encoding: 8bit\n"
|
9 |
-
"
|
10 |
-
"
|
11 |
-
"
|
12 |
-
"X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;_nx_noop:3c,1,2;__ngettext_noop:1,2\n"
|
13 |
-
"X-Poedit-SearchPath-0: .\n"
|
14 |
-
"X-Poedit-SearchPathExcluded-0: *.js\n"
|
15 |
-
"X-Poedit-SearchPathExcluded-1: common\n"
|
16 |
-
"X-Poedit-SearchPathExcluded-2: lang\n"
|
17 |
-
"X-Poedit-SearchPathExcluded-3: tests\n"
|
18 |
-
"X-Poedit-SearchPathExcluded-4: vendor\n"
|
19 |
-
"X-Poedit-SourceCharset: UTF-8\n"
|
20 |
-
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
21 |
|
22 |
-
#: src/
|
23 |
-
msgid "
|
24 |
msgstr ""
|
25 |
|
26 |
-
#: src/
|
27 |
-
msgid "
|
28 |
msgstr ""
|
29 |
|
30 |
-
#: src/
|
31 |
-
msgid "
|
32 |
msgstr ""
|
33 |
|
34 |
-
#: src/
|
35 |
-
msgid "
|
36 |
msgstr ""
|
37 |
|
38 |
-
#: src/
|
39 |
-
|
|
|
40 |
msgstr ""
|
41 |
|
42 |
-
#: src/
|
43 |
-
msgid "
|
|
|
|
|
44 |
msgstr ""
|
45 |
|
46 |
-
#: src/
|
47 |
-
msgid "
|
48 |
msgstr ""
|
49 |
|
50 |
-
#: src/
|
51 |
-
msgid "
|
|
|
|
|
52 |
msgstr ""
|
53 |
|
54 |
-
#: src/
|
55 |
-
msgid "
|
56 |
msgstr ""
|
57 |
|
58 |
-
#: src/
|
59 |
-
msgid "
|
|
|
|
|
60 |
msgstr ""
|
61 |
|
62 |
-
#: src/
|
63 |
-
msgid "
|
64 |
msgstr ""
|
65 |
|
66 |
-
#: src/
|
67 |
-
msgid "
|
68 |
msgstr ""
|
69 |
|
70 |
-
#: src/
|
71 |
-
msgid "
|
72 |
msgstr ""
|
73 |
|
74 |
-
#: src/
|
75 |
-
msgid "
|
76 |
msgstr ""
|
77 |
|
78 |
-
#: src/
|
79 |
-
msgid "
|
80 |
msgstr ""
|
81 |
|
82 |
-
#: src/
|
83 |
-
msgid "
|
84 |
msgstr ""
|
85 |
|
86 |
-
#: src/
|
87 |
-
msgid "
|
88 |
msgstr ""
|
89 |
|
90 |
-
#: src/
|
91 |
-
msgid "
|
92 |
msgstr ""
|
93 |
|
94 |
-
#: src/
|
95 |
-
|
|
|
96 |
msgstr ""
|
97 |
|
98 |
-
#: src/
|
99 |
-
msgid "
|
100 |
msgstr ""
|
101 |
|
102 |
-
#: src/
|
103 |
-
msgid "
|
104 |
msgstr ""
|
105 |
|
106 |
-
#: src/
|
107 |
-
msgid "
|
108 |
msgstr ""
|
109 |
|
110 |
-
#: src/
|
111 |
-
msgid "
|
112 |
msgstr ""
|
113 |
|
114 |
-
#: src/
|
115 |
-
msgid "
|
116 |
msgstr ""
|
117 |
|
118 |
-
#: src/
|
119 |
-
msgid "
|
120 |
msgstr ""
|
121 |
|
122 |
-
#: src/
|
123 |
-
msgid "
|
124 |
msgstr ""
|
125 |
|
126 |
-
#: src/
|
127 |
-
msgid "
|
128 |
msgstr ""
|
129 |
|
130 |
-
#: src/admin-views/
|
131 |
-
msgid "
|
132 |
msgstr ""
|
133 |
|
134 |
-
#: src/
|
135 |
-
msgid "
|
136 |
msgstr ""
|
137 |
|
138 |
-
#: src/
|
139 |
-
msgid "
|
140 |
msgstr ""
|
141 |
|
142 |
-
#: src/
|
143 |
-
msgid "
|
144 |
msgstr ""
|
145 |
|
146 |
-
#: src/
|
147 |
-
msgid "
|
148 |
msgstr ""
|
149 |
|
150 |
-
#: src/
|
151 |
-
msgid "
|
152 |
msgstr ""
|
153 |
|
154 |
-
#: src/
|
155 |
-
msgid "
|
156 |
msgstr ""
|
157 |
|
158 |
-
#: src/
|
159 |
-
msgid "
|
160 |
msgstr ""
|
161 |
|
162 |
-
#: src/
|
163 |
-
msgid "
|
|
|
164 |
msgstr ""
|
165 |
|
166 |
-
#: src/
|
167 |
-
|
|
|
168 |
msgstr ""
|
169 |
|
170 |
-
#: src/
|
171 |
-
|
|
|
172 |
msgstr ""
|
173 |
|
174 |
-
#: src/
|
175 |
-
msgid "
|
176 |
msgstr ""
|
177 |
|
178 |
-
#: src/
|
179 |
-
msgid "
|
180 |
msgstr ""
|
181 |
|
182 |
-
#: src/
|
183 |
-
msgid "
|
184 |
msgstr ""
|
185 |
|
186 |
-
#: src/
|
187 |
-
msgid "
|
188 |
msgstr ""
|
189 |
|
190 |
-
#: src/
|
191 |
-
|
|
|
192 |
msgstr ""
|
193 |
|
194 |
-
#: src/
|
195 |
-
msgid "
|
196 |
msgstr ""
|
197 |
|
198 |
-
#: src/
|
199 |
-
msgid "
|
200 |
msgstr ""
|
201 |
|
202 |
-
#: src/
|
203 |
-
msgid "
|
204 |
msgstr ""
|
205 |
|
206 |
-
#: src/
|
207 |
-
msgid "
|
208 |
msgstr ""
|
209 |
|
210 |
-
#: src/
|
211 |
-
msgid "
|
|
|
|
|
212 |
msgstr ""
|
213 |
|
214 |
-
#: src/
|
215 |
-
msgid "
|
216 |
msgstr ""
|
217 |
|
218 |
-
#: src/
|
219 |
-
msgid "
|
220 |
msgstr ""
|
221 |
|
222 |
-
#: src/
|
223 |
-
msgid "
|
224 |
msgstr ""
|
225 |
|
226 |
-
#: src/
|
227 |
-
msgid "The
|
228 |
msgstr ""
|
229 |
|
230 |
-
#: src/
|
231 |
-
msgid "
|
232 |
msgstr ""
|
233 |
|
234 |
-
#: src/
|
235 |
-
msgid "
|
236 |
msgstr ""
|
237 |
|
238 |
-
#: src/
|
239 |
-
msgid "
|
240 |
msgstr ""
|
241 |
|
242 |
-
#: src/
|
243 |
-
msgid "
|
244 |
msgstr ""
|
245 |
|
246 |
-
#: src/
|
247 |
-
msgid "
|
248 |
msgstr ""
|
249 |
|
250 |
-
#: src/
|
251 |
-
msgid "
|
252 |
msgstr ""
|
253 |
|
254 |
-
#: src/
|
255 |
-
msgid "
|
256 |
msgstr ""
|
257 |
|
258 |
-
#: src/
|
259 |
-
msgid "
|
260 |
msgstr ""
|
261 |
|
262 |
-
#: src/
|
263 |
-
msgid "
|
264 |
msgstr ""
|
265 |
|
266 |
-
#: src/Tribe/
|
267 |
-
msgid "
|
268 |
msgstr ""
|
269 |
|
270 |
-
#: src/Tribe/
|
271 |
-
msgid "
|
272 |
msgstr ""
|
273 |
|
274 |
-
#: src/Tribe/
|
275 |
-
msgid "
|
276 |
msgstr ""
|
277 |
|
278 |
-
#: src/Tribe/
|
279 |
-
msgid "
|
280 |
msgstr ""
|
281 |
|
282 |
-
#: src/Tribe/
|
283 |
-
msgid "The
|
284 |
msgstr ""
|
285 |
|
286 |
-
#: src/Tribe/
|
287 |
-
msgid "
|
288 |
msgstr ""
|
289 |
|
290 |
-
#: src/Tribe/
|
291 |
-
msgid "
|
292 |
msgstr ""
|
293 |
|
294 |
-
#: src/Tribe/
|
295 |
-
msgid "
|
296 |
msgstr ""
|
297 |
|
298 |
-
#: src/Tribe/
|
299 |
-
msgid "
|
300 |
msgstr ""
|
301 |
|
302 |
-
#: src/Tribe/
|
303 |
-
msgid "
|
304 |
msgstr ""
|
305 |
|
306 |
-
#: src/Tribe/
|
307 |
-
msgid "
|
308 |
msgstr ""
|
309 |
|
310 |
-
#: src/Tribe/
|
311 |
-
msgid "
|
312 |
msgstr ""
|
313 |
|
314 |
-
#: src/Tribe/
|
315 |
-
msgid "
|
316 |
msgstr ""
|
317 |
|
318 |
-
#: src/Tribe/
|
319 |
-
msgid "
|
320 |
msgstr ""
|
321 |
|
322 |
-
#: src/Tribe/
|
323 |
-
msgid "
|
324 |
msgstr ""
|
325 |
|
326 |
-
#: src/Tribe/
|
327 |
-
msgid "
|
328 |
msgstr ""
|
329 |
|
330 |
-
#: src/Tribe/
|
331 |
-
msgid "
|
332 |
msgstr ""
|
333 |
|
334 |
-
#: src/Tribe/
|
335 |
-
msgid "
|
|
|
|
|
|
|
|
|
336 |
msgstr ""
|
337 |
|
338 |
-
#: src/Tribe/
|
339 |
-
msgid "
|
340 |
msgstr ""
|
341 |
|
342 |
-
#: src/Tribe/
|
343 |
-
msgid "
|
344 |
msgstr ""
|
345 |
|
346 |
-
#: src/Tribe/
|
347 |
-
msgid "
|
348 |
msgstr ""
|
349 |
|
350 |
-
#: src/Tribe/
|
351 |
-
msgid "
|
352 |
msgstr ""
|
353 |
|
354 |
-
#: src/Tribe/
|
355 |
-
msgid "
|
356 |
msgstr ""
|
357 |
|
358 |
-
#: src/Tribe/
|
359 |
-
msgid "
|
360 |
msgstr ""
|
361 |
|
362 |
-
#: src/Tribe/
|
363 |
-
msgid "
|
364 |
msgstr ""
|
365 |
|
366 |
-
#: src/Tribe/
|
367 |
-
msgid "
|
368 |
msgstr ""
|
369 |
|
370 |
-
#: src/Tribe/
|
371 |
-
msgid "
|
372 |
msgstr ""
|
373 |
|
374 |
-
#: src/Tribe/
|
375 |
-
msgid "
|
376 |
msgstr ""
|
377 |
|
378 |
-
#: src/Tribe/
|
379 |
-
msgid "
|
380 |
msgstr ""
|
381 |
|
382 |
-
#: src/Tribe/
|
383 |
-
msgid "
|
384 |
msgstr ""
|
385 |
|
386 |
-
#: src/Tribe/
|
387 |
-
msgid "
|
388 |
msgstr ""
|
389 |
|
390 |
-
#: src/Tribe/
|
391 |
-
msgid "
|
392 |
msgstr ""
|
393 |
|
394 |
-
#: src/Tribe/
|
395 |
-
msgid "
|
396 |
msgstr ""
|
397 |
|
398 |
-
#: src/Tribe/
|
399 |
-
msgid "
|
400 |
msgstr ""
|
401 |
|
402 |
-
#: src/Tribe/
|
403 |
-
msgid "
|
404 |
msgstr ""
|
405 |
|
406 |
-
#: src/Tribe/
|
407 |
-
msgid "
|
408 |
msgstr ""
|
409 |
|
410 |
-
#: src/Tribe/
|
411 |
-
msgid "
|
412 |
msgstr ""
|
413 |
|
414 |
-
#: src/Tribe/
|
415 |
-
msgid "
|
416 |
msgstr ""
|
417 |
|
418 |
-
#: src/Tribe/
|
419 |
-
msgid "
|
420 |
msgstr ""
|
421 |
|
422 |
-
#: src/Tribe/
|
423 |
-
msgid "
|
424 |
msgstr ""
|
425 |
|
426 |
-
#: src/Tribe/
|
427 |
-
msgid "
|
428 |
msgstr ""
|
429 |
|
430 |
-
#: src/Tribe/
|
431 |
-
msgid "
|
432 |
msgstr ""
|
433 |
|
434 |
-
#: src/Tribe/
|
435 |
-
msgid "
|
436 |
msgstr ""
|
437 |
|
438 |
-
#: src/Tribe/
|
439 |
-
msgid "
|
440 |
msgstr ""
|
441 |
|
442 |
-
#: src/Tribe/
|
443 |
-
msgid "
|
444 |
msgstr ""
|
445 |
|
446 |
-
#: src/Tribe/
|
447 |
-
msgid "
|
448 |
msgstr ""
|
449 |
|
450 |
-
#: src/Tribe/
|
451 |
-
msgid "
|
452 |
msgstr ""
|
453 |
|
454 |
-
#: src/Tribe/
|
455 |
-
msgid "
|
456 |
msgstr ""
|
457 |
|
458 |
-
#: src/Tribe/
|
459 |
-
msgid "
|
460 |
msgstr ""
|
461 |
|
462 |
-
#: src/Tribe/
|
463 |
-
msgid "
|
464 |
msgstr ""
|
465 |
|
466 |
-
#: src/Tribe/
|
467 |
-
msgid "
|
468 |
msgstr ""
|
469 |
|
470 |
-
#: src/Tribe/
|
471 |
-
|
472 |
-
msgid "Event Tickets Plus and Community Events"
|
473 |
msgstr ""
|
474 |
|
475 |
-
#: src/Tribe/
|
476 |
-
msgid "
|
477 |
msgstr ""
|
478 |
|
479 |
-
#: src/Tribe/
|
480 |
-
msgid "
|
481 |
msgstr ""
|
482 |
|
483 |
-
#: src/Tribe/
|
484 |
-
msgid "
|
485 |
msgstr ""
|
486 |
|
487 |
-
#: src/Tribe/
|
488 |
-
msgid "
|
489 |
msgstr ""
|
490 |
|
491 |
-
#: src/Tribe/
|
492 |
-
msgid "
|
493 |
msgstr ""
|
494 |
|
495 |
-
#: src/Tribe/
|
496 |
-
msgid "
|
497 |
msgstr ""
|
498 |
|
499 |
-
#: src/Tribe/
|
500 |
-
msgid "
|
501 |
msgstr ""
|
502 |
|
503 |
-
#: src/Tribe/
|
504 |
-
msgid "
|
505 |
msgstr ""
|
506 |
|
507 |
-
#: src/Tribe/
|
508 |
-
msgid "
|
509 |
msgstr ""
|
510 |
|
511 |
-
#: src/Tribe/
|
512 |
-
msgid "
|
513 |
msgstr ""
|
514 |
|
515 |
-
#: src/Tribe/
|
516 |
-
msgid "
|
517 |
msgstr ""
|
518 |
|
519 |
-
#: src/Tribe/
|
520 |
-
msgid "
|
521 |
msgstr ""
|
522 |
|
523 |
-
#: src/Tribe/
|
524 |
-
msgid "
|
525 |
msgstr ""
|
526 |
|
527 |
-
#: src/Tribe/
|
528 |
-
msgid "
|
529 |
msgstr ""
|
530 |
|
531 |
-
#: src/Tribe/
|
532 |
-
msgid "
|
533 |
msgstr ""
|
534 |
|
535 |
-
#: src/Tribe/
|
536 |
-
msgid "
|
537 |
-
|
538 |
-
msgstr[0] ""
|
539 |
-
msgstr[1] ""
|
540 |
|
541 |
-
#: src/Tribe/
|
542 |
-
msgid "
|
543 |
msgstr ""
|
544 |
|
545 |
-
#: src/Tribe/
|
546 |
-
msgid "
|
547 |
msgstr ""
|
548 |
|
549 |
-
#: src/Tribe/
|
550 |
-
msgid "
|
551 |
msgstr ""
|
552 |
|
553 |
-
#: src/Tribe/
|
554 |
-
msgid "
|
555 |
msgstr ""
|
556 |
|
557 |
-
#: src/Tribe/
|
558 |
-
msgid "
|
559 |
msgstr ""
|
560 |
|
561 |
-
#: src/Tribe/
|
562 |
-
msgid "
|
563 |
msgstr ""
|
564 |
|
565 |
-
#: src/Tribe/
|
566 |
-
msgid "
|
567 |
msgstr ""
|
568 |
|
569 |
-
#: src/Tribe/
|
570 |
-
msgid "
|
571 |
msgstr ""
|
572 |
|
573 |
-
#: src/Tribe/
|
574 |
-
msgid "
|
575 |
msgstr ""
|
576 |
|
577 |
-
#: src/Tribe/
|
578 |
-
msgid "
|
579 |
msgstr ""
|
580 |
|
581 |
-
#: src/Tribe/
|
582 |
-
msgid "
|
583 |
msgstr ""
|
584 |
|
585 |
-
#: src/Tribe/
|
586 |
-
msgid "
|
587 |
msgstr ""
|
588 |
|
589 |
-
#: src/Tribe/
|
590 |
-
msgid "
|
591 |
msgstr ""
|
592 |
|
593 |
-
#: src/Tribe/
|
594 |
-
msgid "
|
595 |
msgstr ""
|
596 |
|
597 |
-
#: src/Tribe/
|
598 |
-
msgid "
|
599 |
msgstr ""
|
600 |
|
601 |
-
#: src/Tribe/
|
602 |
-
msgid "
|
603 |
msgstr ""
|
604 |
|
605 |
-
#: src/Tribe/
|
606 |
-
msgid "
|
607 |
msgstr ""
|
608 |
|
609 |
-
#: src/Tribe/
|
610 |
-
|
611 |
-
msgid "with function name:"
|
612 |
msgstr ""
|
613 |
|
614 |
-
#: src/Tribe/
|
615 |
-
msgid "
|
616 |
msgstr ""
|
617 |
|
618 |
-
#: src/Tribe/
|
619 |
-
msgid "
|
620 |
msgstr ""
|
621 |
|
622 |
-
#: src/Tribe/
|
623 |
-
msgid "
|
624 |
msgstr ""
|
625 |
|
626 |
-
#: src/Tribe/
|
627 |
-
msgid "
|
628 |
msgstr ""
|
629 |
|
630 |
-
#: src/Tribe/
|
631 |
-
msgid "
|
632 |
msgstr ""
|
633 |
|
634 |
-
#: src/Tribe/
|
635 |
-
msgid "
|
636 |
msgstr ""
|
637 |
|
638 |
-
#: src/Tribe/
|
639 |
-
msgid "
|
640 |
msgstr ""
|
641 |
|
642 |
-
#: src/Tribe/
|
643 |
-
msgid "
|
644 |
msgstr ""
|
645 |
|
646 |
-
#: src/Tribe/
|
647 |
-
msgid "
|
648 |
msgstr ""
|
649 |
|
650 |
-
#: src/Tribe/
|
651 |
-
msgid "
|
652 |
msgstr ""
|
653 |
|
654 |
-
#: src/Tribe/
|
655 |
-
msgid "
|
656 |
msgstr ""
|
657 |
|
658 |
-
#: src/Tribe/
|
659 |
-
msgid "
|
660 |
msgstr ""
|
661 |
|
662 |
-
#: src/Tribe/
|
663 |
-
msgid "
|
664 |
msgstr ""
|
665 |
|
666 |
-
#: src/Tribe/
|
667 |
-
msgid "
|
668 |
msgstr ""
|
669 |
|
670 |
-
#: src/Tribe/
|
671 |
-
msgid "
|
672 |
msgstr ""
|
673 |
|
674 |
-
#: src/Tribe/
|
675 |
-
msgid "
|
676 |
msgstr ""
|
677 |
|
678 |
-
#: src/Tribe/
|
679 |
-
msgid "
|
680 |
msgstr ""
|
681 |
|
682 |
-
#: src/Tribe/
|
683 |
-
msgid "
|
684 |
msgstr ""
|
685 |
|
686 |
-
#: src/Tribe/
|
687 |
-
msgid "
|
688 |
msgstr ""
|
689 |
|
690 |
-
#: src/Tribe/
|
691 |
-
msgid "
|
692 |
msgstr ""
|
693 |
|
694 |
-
#: src/Tribe/
|
695 |
-
msgid "
|
696 |
msgstr ""
|
697 |
|
698 |
-
#: src/Tribe/
|
699 |
-
msgid "
|
700 |
msgstr ""
|
701 |
|
702 |
-
#: src/Tribe/
|
703 |
-
msgid "
|
704 |
msgstr ""
|
705 |
|
706 |
-
#: src/Tribe/
|
707 |
-
msgid "
|
708 |
msgstr ""
|
709 |
|
710 |
-
#: src/Tribe/
|
711 |
-
msgid "
|
712 |
msgstr ""
|
713 |
|
714 |
-
#: src/Tribe/
|
715 |
-
msgid "
|
716 |
msgstr ""
|
717 |
|
718 |
-
#: src/Tribe/
|
719 |
-
msgid "
|
720 |
msgstr ""
|
721 |
|
722 |
-
#: src/Tribe/
|
723 |
-
msgid "
|
724 |
msgstr ""
|
725 |
|
726 |
-
#: src/Tribe/
|
727 |
-
msgid "
|
728 |
msgstr ""
|
729 |
|
730 |
-
#: src/Tribe/
|
731 |
-
|
732 |
-
msgid "n/a"
|
733 |
msgstr ""
|
734 |
|
735 |
-
#: src/Tribe/
|
736 |
-
msgid "
|
737 |
msgstr ""
|
738 |
|
739 |
-
#: src/Tribe/
|
740 |
-
msgid "
|
741 |
msgstr ""
|
742 |
|
743 |
-
#: src/Tribe/
|
744 |
-
msgid "
|
745 |
msgstr ""
|
746 |
|
747 |
-
#: src/Tribe/
|
748 |
-
msgid "
|
749 |
msgstr ""
|
750 |
|
751 |
-
#: src/Tribe/
|
752 |
-
msgid "
|
753 |
msgstr ""
|
754 |
|
755 |
-
#: src/Tribe/
|
756 |
-
msgid "
|
757 |
msgstr ""
|
758 |
|
759 |
-
#: src/Tribe/
|
760 |
-
msgid "
|
761 |
msgstr ""
|
762 |
|
763 |
-
#: src/Tribe/
|
764 |
-
msgid "
|
765 |
msgstr ""
|
766 |
|
767 |
-
#: src/Tribe/
|
768 |
-
msgid "
|
769 |
msgstr ""
|
770 |
|
771 |
-
#: src/Tribe/
|
772 |
-
msgid "
|
773 |
msgstr ""
|
774 |
|
775 |
-
#: src/Tribe/
|
776 |
-
msgid "
|
777 |
msgstr ""
|
778 |
|
779 |
-
#: src/Tribe/
|
780 |
-
msgid "
|
781 |
msgstr ""
|
782 |
|
783 |
-
#: src/Tribe/
|
784 |
-
msgid "
|
785 |
msgstr ""
|
786 |
|
787 |
-
#: src/Tribe/
|
788 |
-
msgid "
|
789 |
msgstr ""
|
790 |
|
791 |
-
#: src/Tribe/
|
792 |
-
msgid "
|
793 |
msgstr ""
|
794 |
|
795 |
-
#: src/Tribe/
|
796 |
-
msgid "
|
797 |
msgstr ""
|
798 |
|
799 |
-
#: src/Tribe/
|
800 |
-
msgid "
|
801 |
msgstr ""
|
802 |
|
803 |
-
#: src/Tribe/
|
804 |
-
msgid "
|
805 |
msgstr ""
|
806 |
|
807 |
-
#: src/Tribe/
|
808 |
-
msgid "
|
809 |
msgstr ""
|
810 |
|
811 |
-
#: src/Tribe/Languages/Locations.php:
|
812 |
-
msgid "
|
813 |
msgstr ""
|
814 |
|
815 |
-
#: src/Tribe/Languages/Locations.php:
|
816 |
-
msgid "
|
817 |
msgstr ""
|
818 |
|
819 |
-
#: src/Tribe/Languages/Locations.php:
|
820 |
-
msgid "
|
821 |
msgstr ""
|
822 |
|
823 |
-
#: src/Tribe/Languages/Locations.php:
|
824 |
-
msgid "
|
825 |
msgstr ""
|
826 |
|
827 |
-
#: src/Tribe/Languages/Locations.php:
|
828 |
-
msgid "
|
829 |
msgstr ""
|
830 |
|
831 |
-
#: src/Tribe/Languages/Locations.php:
|
832 |
-
msgid "
|
833 |
msgstr ""
|
834 |
|
835 |
-
#: src/Tribe/Languages/Locations.php:
|
836 |
-
msgid "
|
837 |
msgstr ""
|
838 |
|
839 |
-
#: src/Tribe/Languages/Locations.php:
|
840 |
-
msgid "
|
841 |
msgstr ""
|
842 |
|
843 |
-
#: src/Tribe/Languages/Locations.php:
|
844 |
-
msgid "
|
845 |
msgstr ""
|
846 |
|
847 |
-
#: src/Tribe/Languages/Locations.php:
|
848 |
-
msgid "
|
849 |
msgstr ""
|
850 |
|
851 |
-
#: src/Tribe/Languages/Locations.php:
|
852 |
-
msgid "
|
853 |
msgstr ""
|
854 |
|
855 |
-
#: src/Tribe/Languages/Locations.php:
|
856 |
-
msgid "
|
857 |
msgstr ""
|
858 |
|
859 |
-
#: src/Tribe/Languages/Locations.php:
|
860 |
-
msgid "
|
861 |
msgstr ""
|
862 |
|
863 |
-
#: src/Tribe/Languages/Locations.php:
|
864 |
-
msgid "
|
865 |
msgstr ""
|
866 |
|
867 |
-
#: src/Tribe/Languages/Locations.php:
|
868 |
-
msgid "
|
869 |
msgstr ""
|
870 |
|
871 |
-
#: src/Tribe/Languages/Locations.php:
|
872 |
-
msgid "
|
873 |
msgstr ""
|
874 |
|
875 |
-
#: src/Tribe/Languages/Locations.php:
|
876 |
-
msgid "
|
877 |
msgstr ""
|
878 |
|
879 |
-
#: src/Tribe/Languages/Locations.php:
|
880 |
-
msgid "
|
881 |
msgstr ""
|
882 |
|
883 |
-
#: src/Tribe/Languages/Locations.php:
|
884 |
-
msgid "
|
885 |
msgstr ""
|
886 |
|
887 |
-
#: src/Tribe/Languages/Locations.php:
|
888 |
-
msgid "
|
889 |
msgstr ""
|
890 |
|
891 |
-
#: src/Tribe/Languages/Locations.php:
|
892 |
-
msgid "
|
893 |
msgstr ""
|
894 |
|
895 |
-
#: src/Tribe/Languages/Locations.php:
|
896 |
-
msgid "
|
897 |
msgstr ""
|
898 |
|
899 |
-
#: src/Tribe/Languages/Locations.php:
|
900 |
-
msgid "
|
901 |
msgstr ""
|
902 |
|
903 |
-
#: src/Tribe/Languages/Locations.php:
|
904 |
-
msgid "
|
905 |
msgstr ""
|
906 |
|
907 |
-
#: src/Tribe/Languages/Locations.php:
|
908 |
-
msgid "
|
909 |
msgstr ""
|
910 |
|
911 |
-
#: src/Tribe/Languages/Locations.php:
|
912 |
-
msgid "
|
913 |
msgstr ""
|
914 |
|
915 |
-
#: src/Tribe/Languages/Locations.php:
|
916 |
-
msgid "
|
917 |
msgstr ""
|
918 |
|
919 |
-
#: src/Tribe/Languages/Locations.php:
|
920 |
-
msgid "
|
921 |
msgstr ""
|
922 |
|
923 |
-
#: src/Tribe/Languages/Locations.php:
|
924 |
-
msgid "
|
925 |
msgstr ""
|
926 |
|
927 |
-
#: src/Tribe/Languages/Locations.php:
|
928 |
-
msgid "
|
929 |
msgstr ""
|
930 |
|
931 |
-
#: src/Tribe/Languages/Locations.php:
|
932 |
-
msgid "
|
933 |
msgstr ""
|
934 |
|
935 |
-
#: src/Tribe/Languages/Locations.php:
|
936 |
-
msgid "
|
937 |
msgstr ""
|
938 |
|
939 |
-
#: src/Tribe/Languages/Locations.php:
|
940 |
-
msgid "
|
941 |
msgstr ""
|
942 |
|
943 |
-
#: src/Tribe/Languages/Locations.php:
|
944 |
-
msgid "
|
945 |
msgstr ""
|
946 |
|
947 |
-
#: src/Tribe/Languages/Locations.php:
|
948 |
-
msgid "
|
949 |
msgstr ""
|
950 |
|
951 |
-
#: src/Tribe/Languages/Locations.php:
|
952 |
-
msgid "
|
953 |
msgstr ""
|
954 |
|
955 |
-
#: src/Tribe/Languages/Locations.php:
|
956 |
-
msgid "
|
957 |
msgstr ""
|
958 |
|
959 |
-
#: src/Tribe/Languages/Locations.php:
|
960 |
-
msgid "
|
961 |
msgstr ""
|
962 |
|
963 |
-
#: src/Tribe/Languages/Locations.php:
|
964 |
-
msgid "
|
965 |
msgstr ""
|
966 |
|
967 |
-
#: src/Tribe/Languages/Locations.php:
|
968 |
-
msgid "
|
969 |
msgstr ""
|
970 |
|
971 |
-
#: src/Tribe/Languages/Locations.php:
|
972 |
-
msgid "
|
973 |
msgstr ""
|
974 |
|
975 |
-
#: src/Tribe/Languages/Locations.php:
|
976 |
-
msgid "
|
977 |
msgstr ""
|
978 |
|
979 |
-
#: src/Tribe/Languages/Locations.php:
|
980 |
-
msgid "
|
981 |
msgstr ""
|
982 |
|
983 |
-
#: src/Tribe/Languages/Locations.php:
|
984 |
-
msgid "
|
985 |
msgstr ""
|
986 |
|
987 |
-
#: src/Tribe/Languages/Locations.php:
|
988 |
-
msgid "
|
989 |
msgstr ""
|
990 |
|
991 |
-
#: src/Tribe/Languages/Locations.php:
|
992 |
-
msgid "
|
993 |
msgstr ""
|
994 |
|
995 |
-
#: src/Tribe/Languages/Locations.php:
|
996 |
-
msgid "
|
997 |
msgstr ""
|
998 |
|
999 |
-
#: src/Tribe/Languages/Locations.php:
|
1000 |
-
msgid "
|
1001 |
msgstr ""
|
1002 |
|
1003 |
-
#: src/Tribe/Languages/Locations.php:
|
1004 |
-
msgid "
|
1005 |
msgstr ""
|
1006 |
|
1007 |
-
#: src/Tribe/Languages/Locations.php:
|
1008 |
-
msgid "
|
1009 |
msgstr ""
|
1010 |
|
1011 |
-
#: src/Tribe/Languages/Locations.php:
|
1012 |
-
msgid "
|
1013 |
msgstr ""
|
1014 |
|
1015 |
-
#: src/Tribe/Languages/Locations.php:
|
1016 |
-
msgid "
|
1017 |
msgstr ""
|
1018 |
|
1019 |
-
#: src/Tribe/Languages/Locations.php:
|
1020 |
-
msgid "
|
1021 |
msgstr ""
|
1022 |
|
1023 |
-
#: src/Tribe/Languages/Locations.php:
|
1024 |
-
msgid "
|
1025 |
msgstr ""
|
1026 |
|
1027 |
-
#: src/Tribe/Languages/Locations.php:
|
1028 |
-
msgid "
|
1029 |
msgstr ""
|
1030 |
|
1031 |
-
#: src/Tribe/Languages/Locations.php:
|
1032 |
-
msgid "
|
1033 |
msgstr ""
|
1034 |
|
1035 |
-
#: src/Tribe/Languages/Locations.php:
|
1036 |
-
msgid "
|
1037 |
msgstr ""
|
1038 |
|
1039 |
-
#: src/Tribe/Languages/Locations.php:
|
1040 |
-
msgid "
|
1041 |
msgstr ""
|
1042 |
|
1043 |
-
#: src/Tribe/Languages/Locations.php:
|
1044 |
-
msgid "
|
1045 |
msgstr ""
|
1046 |
|
1047 |
-
#: src/Tribe/Languages/Locations.php:
|
1048 |
-
msgid "
|
1049 |
msgstr ""
|
1050 |
|
1051 |
-
#: src/Tribe/Languages/Locations.php:
|
1052 |
-
msgid "
|
1053 |
msgstr ""
|
1054 |
|
1055 |
-
#: src/Tribe/Languages/Locations.php:
|
1056 |
-
msgid "
|
1057 |
msgstr ""
|
1058 |
|
1059 |
-
#: src/Tribe/Languages/Locations.php:
|
1060 |
-
msgid "
|
1061 |
msgstr ""
|
1062 |
|
1063 |
-
#: src/Tribe/Languages/Locations.php:
|
1064 |
-
msgid "
|
1065 |
msgstr ""
|
1066 |
|
1067 |
-
#: src/Tribe/Languages/Locations.php:
|
1068 |
-
msgid "
|
1069 |
msgstr ""
|
1070 |
|
1071 |
-
#: src/Tribe/Languages/Locations.php:
|
1072 |
-
msgid "
|
1073 |
msgstr ""
|
1074 |
|
1075 |
-
#: src/Tribe/Languages/Locations.php:
|
1076 |
-
msgid "
|
1077 |
msgstr ""
|
1078 |
|
1079 |
-
#: src/Tribe/Languages/Locations.php:
|
1080 |
-
msgid "
|
1081 |
msgstr ""
|
1082 |
|
1083 |
-
#: src/Tribe/Languages/Locations.php:
|
1084 |
-
msgid "
|
1085 |
msgstr ""
|
1086 |
|
1087 |
-
#: src/Tribe/Languages/Locations.php:
|
1088 |
-
msgid "
|
1089 |
msgstr ""
|
1090 |
|
1091 |
-
#: src/Tribe/Languages/Locations.php:
|
1092 |
-
msgid "
|
1093 |
msgstr ""
|
1094 |
|
1095 |
-
#: src/Tribe/Languages/Locations.php:
|
1096 |
-
msgid "
|
1097 |
msgstr ""
|
1098 |
|
1099 |
-
#: src/Tribe/Languages/Locations.php:
|
1100 |
-
msgid "
|
1101 |
msgstr ""
|
1102 |
|
1103 |
-
#: src/Tribe/Languages/Locations.php:
|
1104 |
-
msgid "
|
1105 |
msgstr ""
|
1106 |
|
1107 |
-
#: src/Tribe/Languages/Locations.php:
|
1108 |
-
msgid "
|
1109 |
msgstr ""
|
1110 |
|
1111 |
-
#: src/Tribe/Languages/Locations.php:
|
1112 |
-
msgid "
|
1113 |
msgstr ""
|
1114 |
|
1115 |
-
#: src/Tribe/Languages/Locations.php:
|
1116 |
-
msgid "
|
1117 |
msgstr ""
|
1118 |
|
1119 |
-
#: src/Tribe/Languages/Locations.php:
|
1120 |
-
msgid "
|
1121 |
msgstr ""
|
1122 |
|
1123 |
-
#: src/Tribe/Languages/Locations.php:
|
1124 |
-
msgid "
|
1125 |
msgstr ""
|
1126 |
|
1127 |
-
#: src/Tribe/Languages/Locations.php:
|
1128 |
-
msgid "
|
1129 |
msgstr ""
|
1130 |
|
1131 |
-
#: src/Tribe/Languages/Locations.php:
|
1132 |
-
msgid "
|
1133 |
msgstr ""
|
1134 |
|
1135 |
-
#: src/Tribe/Languages/Locations.php:
|
1136 |
-
msgid "
|
1137 |
msgstr ""
|
1138 |
|
1139 |
-
#: src/Tribe/Languages/Locations.php:
|
1140 |
-
msgid "
|
1141 |
msgstr ""
|
1142 |
|
1143 |
-
#: src/Tribe/Languages/Locations.php:
|
1144 |
-
msgid "
|
1145 |
msgstr ""
|
1146 |
|
1147 |
-
#: src/Tribe/Languages/Locations.php:
|
1148 |
-
msgid "
|
1149 |
msgstr ""
|
1150 |
|
1151 |
-
#: src/Tribe/Languages/Locations.php:
|
1152 |
-
msgid "
|
1153 |
msgstr ""
|
1154 |
|
1155 |
-
#: src/Tribe/Languages/Locations.php:
|
1156 |
-
msgid "
|
1157 |
msgstr ""
|
1158 |
|
1159 |
-
#: src/Tribe/Languages/Locations.php:
|
1160 |
-
msgid "
|
1161 |
msgstr ""
|
1162 |
|
1163 |
-
#: src/Tribe/Languages/Locations.php:
|
1164 |
-
msgid "
|
1165 |
msgstr ""
|
1166 |
|
1167 |
-
#: src/Tribe/Languages/Locations.php:
|
1168 |
-
msgid "
|
1169 |
msgstr ""
|
1170 |
|
1171 |
-
#: src/Tribe/Languages/Locations.php:
|
1172 |
-
msgid "
|
1173 |
msgstr ""
|
1174 |
|
1175 |
-
#: src/Tribe/Languages/Locations.php:
|
1176 |
-
msgid "
|
1177 |
msgstr ""
|
1178 |
|
1179 |
-
#: src/Tribe/Languages/Locations.php:
|
1180 |
-
msgid "
|
1181 |
msgstr ""
|
1182 |
|
1183 |
-
#: src/Tribe/Languages/Locations.php:
|
1184 |
-
msgid "
|
1185 |
msgstr ""
|
1186 |
|
1187 |
-
#: src/Tribe/Languages/Locations.php:
|
1188 |
-
msgid "
|
1189 |
msgstr ""
|
1190 |
|
1191 |
-
#: src/Tribe/Languages/Locations.php:
|
1192 |
-
msgid "
|
1193 |
msgstr ""
|
1194 |
|
1195 |
-
#: src/Tribe/Languages/Locations.php:
|
1196 |
-
msgid "
|
1197 |
msgstr ""
|
1198 |
|
1199 |
-
#: src/Tribe/Languages/Locations.php:
|
1200 |
-
msgid "
|
1201 |
msgstr ""
|
1202 |
|
1203 |
-
#: src/Tribe/Languages/Locations.php:
|
1204 |
-
msgid "
|
1205 |
msgstr ""
|
1206 |
|
1207 |
-
#: src/Tribe/Languages/Locations.php:
|
1208 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1209 |
msgstr ""
|
1210 |
|
1211 |
-
#: src/Tribe/Languages/Locations.php:
|
1212 |
-
msgid "
|
1213 |
msgstr ""
|
1214 |
|
1215 |
-
#: src/Tribe/Languages/Locations.php:
|
1216 |
-
msgid "
|
1217 |
msgstr ""
|
1218 |
|
1219 |
-
#: src/Tribe/Languages/Locations.php:
|
1220 |
-
msgid "
|
1221 |
msgstr ""
|
1222 |
|
1223 |
-
#: src/Tribe/Languages/Locations.php:
|
1224 |
-
msgid "
|
1225 |
msgstr ""
|
1226 |
|
1227 |
-
#: src/Tribe/Languages/Locations.php:
|
1228 |
-
msgid "
|
1229 |
msgstr ""
|
1230 |
|
1231 |
-
#: src/Tribe/Languages/Locations.php:
|
1232 |
-
msgid "
|
1233 |
msgstr ""
|
1234 |
|
1235 |
-
#: src/Tribe/Languages/Locations.php:
|
1236 |
-
msgid "
|
1237 |
msgstr ""
|
1238 |
|
1239 |
-
#: src/Tribe/Languages/Locations.php:
|
1240 |
-
msgid "
|
1241 |
msgstr ""
|
1242 |
|
1243 |
-
#: src/Tribe/Languages/Locations.php:
|
1244 |
-
msgid "
|
1245 |
msgstr ""
|
1246 |
|
1247 |
-
#: src/Tribe/Languages/Locations.php:
|
1248 |
-
msgid "
|
1249 |
msgstr ""
|
1250 |
|
1251 |
-
#: src/Tribe/Languages/Locations.php:
|
1252 |
-
msgid "
|
1253 |
msgstr ""
|
1254 |
|
1255 |
-
#: src/Tribe/Languages/Locations.php:
|
1256 |
-
msgid "
|
1257 |
msgstr ""
|
1258 |
|
1259 |
-
#: src/Tribe/Languages/Locations.php:
|
1260 |
-
msgid "
|
1261 |
msgstr ""
|
1262 |
|
1263 |
-
#: src/Tribe/Languages/Locations.php:
|
1264 |
-
msgid "
|
1265 |
msgstr ""
|
1266 |
|
1267 |
-
#: src/Tribe/Languages/Locations.php:
|
1268 |
-
msgid "
|
1269 |
msgstr ""
|
1270 |
|
1271 |
-
#: src/Tribe/Languages/Locations.php:
|
1272 |
-
msgid "
|
1273 |
msgstr ""
|
1274 |
|
1275 |
-
#: src/Tribe/Languages/Locations.php:
|
1276 |
-
msgid "
|
1277 |
msgstr ""
|
1278 |
|
1279 |
-
#: src/Tribe/Languages/Locations.php:
|
1280 |
-
msgid "
|
1281 |
msgstr ""
|
1282 |
|
1283 |
-
#: src/Tribe/Languages/Locations.php:
|
1284 |
-
msgid "
|
1285 |
msgstr ""
|
1286 |
|
1287 |
-
#: src/Tribe/Languages/Locations.php:
|
1288 |
-
msgid "
|
1289 |
msgstr ""
|
1290 |
|
1291 |
-
#: src/Tribe/Languages/Locations.php:
|
1292 |
-
msgid "
|
1293 |
msgstr ""
|
1294 |
|
1295 |
-
#: src/Tribe/Languages/Locations.php:
|
1296 |
-
msgid "
|
1297 |
msgstr ""
|
1298 |
|
1299 |
-
#: src/Tribe/Languages/Locations.php:
|
1300 |
-
msgid "
|
1301 |
msgstr ""
|
1302 |
|
1303 |
-
#: src/Tribe/Languages/Locations.php:
|
1304 |
-
msgid "
|
1305 |
msgstr ""
|
1306 |
|
1307 |
-
#: src/Tribe/Languages/Locations.php:
|
1308 |
-
msgid "
|
1309 |
msgstr ""
|
1310 |
|
1311 |
-
#: src/Tribe/Languages/Locations.php:
|
1312 |
-
msgid "
|
1313 |
msgstr ""
|
1314 |
|
1315 |
-
#: src/Tribe/Languages/Locations.php:
|
1316 |
-
msgid "
|
1317 |
msgstr ""
|
1318 |
|
1319 |
-
#: src/Tribe/Languages/Locations.php:
|
1320 |
-
msgid "
|
1321 |
msgstr ""
|
1322 |
|
1323 |
-
#: src/Tribe/Languages/Locations.php:
|
1324 |
-
msgid "
|
1325 |
msgstr ""
|
1326 |
|
1327 |
-
#: src/Tribe/Languages/Locations.php:
|
1328 |
-
msgid "
|
1329 |
msgstr ""
|
1330 |
|
1331 |
-
#: src/Tribe/Languages/Locations.php:
|
1332 |
-
msgid "
|
1333 |
msgstr ""
|
1334 |
|
1335 |
-
#: src/Tribe/Languages/Locations.php:
|
1336 |
-
msgid "
|
1337 |
msgstr ""
|
1338 |
|
1339 |
-
#: src/Tribe/Languages/Locations.php:
|
1340 |
-
msgid "
|
1341 |
msgstr ""
|
1342 |
|
1343 |
-
#: src/Tribe/Languages/Locations.php:
|
1344 |
-
msgid "
|
1345 |
msgstr ""
|
1346 |
|
1347 |
-
#: src/Tribe/Languages/Locations.php:
|
1348 |
-
msgid "
|
1349 |
msgstr ""
|
1350 |
|
1351 |
-
#: src/Tribe/Languages/Locations.php:
|
1352 |
-
msgid "
|
1353 |
msgstr ""
|
1354 |
|
1355 |
-
#: src/Tribe/Languages/Locations.php:
|
1356 |
-
msgid "
|
1357 |
msgstr ""
|
1358 |
|
1359 |
-
#: src/Tribe/Languages/Locations.php:
|
1360 |
-
msgid "
|
1361 |
msgstr ""
|
1362 |
|
1363 |
-
#: src/Tribe/Languages/Locations.php:
|
1364 |
-
msgid "
|
1365 |
msgstr ""
|
1366 |
|
1367 |
-
#: src/Tribe/Languages/Locations.php:
|
1368 |
-
msgid "
|
1369 |
msgstr ""
|
1370 |
|
1371 |
-
#: src/Tribe/Languages/Locations.php:
|
1372 |
-
msgid "
|
1373 |
msgstr ""
|
1374 |
|
1375 |
-
#: src/Tribe/Languages/Locations.php:
|
1376 |
-
msgid "
|
1377 |
msgstr ""
|
1378 |
|
1379 |
-
#: src/Tribe/Languages/Locations.php:
|
1380 |
-
msgid "
|
1381 |
msgstr ""
|
1382 |
|
1383 |
-
#: src/Tribe/Languages/Locations.php:
|
1384 |
-
msgid "
|
1385 |
msgstr ""
|
1386 |
|
1387 |
-
#: src/Tribe/Languages/Locations.php:
|
1388 |
-
msgid "
|
1389 |
msgstr ""
|
1390 |
|
1391 |
-
#: src/Tribe/Languages/Locations.php:
|
1392 |
-
msgid "
|
1393 |
msgstr ""
|
1394 |
|
1395 |
-
#: src/Tribe/Languages/Locations.php:
|
1396 |
-
msgid "
|
1397 |
msgstr ""
|
1398 |
|
1399 |
-
#: src/Tribe/Languages/Locations.php:
|
1400 |
-
msgid "
|
1401 |
msgstr ""
|
1402 |
|
1403 |
-
#: src/Tribe/Languages/Locations.php:
|
1404 |
-
msgid "
|
1405 |
msgstr ""
|
1406 |
|
1407 |
-
#: src/Tribe/Languages/Locations.php:
|
1408 |
-
msgid "
|
1409 |
msgstr ""
|
1410 |
|
1411 |
-
#: src/Tribe/Languages/Locations.php:
|
1412 |
-
msgid "
|
1413 |
msgstr ""
|
1414 |
|
1415 |
-
#: src/Tribe/Languages/Locations.php:
|
1416 |
-
msgid "
|
1417 |
msgstr ""
|
1418 |
|
1419 |
-
#: src/Tribe/Languages/Locations.php:
|
1420 |
-
msgid "
|
1421 |
msgstr ""
|
1422 |
|
1423 |
-
#: src/Tribe/Languages/Locations.php:
|
1424 |
-
msgid "
|
1425 |
msgstr ""
|
1426 |
|
1427 |
-
#: src/Tribe/Languages/Locations.php:
|
1428 |
-
msgid "
|
1429 |
msgstr ""
|
1430 |
|
1431 |
-
#: src/Tribe/Languages/Locations.php:
|
1432 |
-
msgid "
|
1433 |
msgstr ""
|
1434 |
|
1435 |
-
#: src/Tribe/Languages/Locations.php:
|
1436 |
-
msgid "
|
1437 |
msgstr ""
|
1438 |
|
1439 |
-
#: src/Tribe/Languages/Locations.php:
|
1440 |
-
msgid "
|
1441 |
msgstr ""
|
1442 |
|
1443 |
-
#: src/Tribe/Languages/Locations.php:
|
1444 |
-
msgid "
|
1445 |
msgstr ""
|
1446 |
|
1447 |
-
#: src/Tribe/Languages/Locations.php:
|
1448 |
-
msgid "
|
1449 |
msgstr ""
|
1450 |
|
1451 |
-
#: src/Tribe/Languages/Locations.php:
|
1452 |
-
msgid "
|
1453 |
msgstr ""
|
1454 |
|
1455 |
-
#: src/Tribe/Languages/Locations.php:
|
1456 |
-
msgid "
|
1457 |
msgstr ""
|
1458 |
|
1459 |
-
#: src/Tribe/Languages/Locations.php:
|
1460 |
-
msgid "
|
1461 |
msgstr ""
|
1462 |
|
1463 |
-
#: src/Tribe/Languages/Locations.php:
|
1464 |
-
msgid "
|
1465 |
msgstr ""
|
1466 |
|
1467 |
-
#: src/Tribe/Languages/Locations.php:
|
1468 |
-
msgid "
|
1469 |
msgstr ""
|
1470 |
|
1471 |
-
#: src/Tribe/Languages/Locations.php:
|
1472 |
-
msgid "
|
1473 |
msgstr ""
|
1474 |
|
1475 |
-
#: src/Tribe/Languages/Locations.php:
|
1476 |
-
msgid "
|
1477 |
msgstr ""
|
1478 |
|
1479 |
-
#: src/Tribe/Languages/Locations.php:
|
1480 |
-
msgid "
|
1481 |
msgstr ""
|
1482 |
|
1483 |
-
#: src/Tribe/Languages/Locations.php:
|
1484 |
-
msgid "
|
1485 |
msgstr ""
|
1486 |
|
1487 |
-
#: src/Tribe/
|
1488 |
-
|
|
|
1489 |
msgstr ""
|
1490 |
|
1491 |
-
#: src/Tribe/
|
1492 |
-
|
|
|
1493 |
msgstr ""
|
1494 |
|
1495 |
-
#: src/Tribe/
|
1496 |
-
msgid "
|
1497 |
msgstr ""
|
1498 |
|
1499 |
-
#: src/Tribe/
|
1500 |
-
msgid "
|
1501 |
msgstr ""
|
1502 |
|
1503 |
-
#: src/Tribe/
|
1504 |
-
msgid "
|
1505 |
msgstr ""
|
1506 |
|
1507 |
-
#: src/Tribe/
|
1508 |
-
msgid "
|
1509 |
msgstr ""
|
1510 |
|
1511 |
-
#: src/Tribe/
|
1512 |
-
msgid "
|
1513 |
msgstr ""
|
1514 |
|
1515 |
-
#: src/Tribe/
|
1516 |
-
msgid "
|
1517 |
msgstr ""
|
1518 |
|
1519 |
-
#: src/Tribe/
|
1520 |
-
msgid "
|
1521 |
msgstr ""
|
1522 |
|
1523 |
-
#: src/Tribe/
|
1524 |
-
msgid "
|
1525 |
msgstr ""
|
1526 |
|
1527 |
-
#: src/Tribe/
|
1528 |
-
msgid "
|
1529 |
msgstr ""
|
1530 |
|
1531 |
-
#: src/Tribe/
|
1532 |
-
msgid "
|
1533 |
msgstr ""
|
1534 |
|
1535 |
-
#: src/Tribe/
|
1536 |
-
msgid "
|
1537 |
msgstr ""
|
1538 |
|
1539 |
-
#: src/Tribe/
|
1540 |
-
msgid "
|
1541 |
msgstr ""
|
1542 |
|
1543 |
-
#: src/Tribe/
|
1544 |
-
msgid "
|
1545 |
msgstr ""
|
1546 |
|
1547 |
-
#: src/Tribe/
|
1548 |
-
msgid "
|
1549 |
msgstr ""
|
1550 |
|
1551 |
-
#: src/Tribe/
|
1552 |
-
msgid "
|
1553 |
msgstr ""
|
1554 |
|
1555 |
-
#: src/Tribe/
|
1556 |
-
msgid "
|
1557 |
msgstr ""
|
1558 |
|
1559 |
-
#: src/Tribe/
|
1560 |
-
msgid "
|
1561 |
msgstr ""
|
1562 |
|
1563 |
-
#: src/Tribe/
|
1564 |
-
msgid "
|
1565 |
msgstr ""
|
1566 |
|
1567 |
-
#: src/Tribe/
|
1568 |
-
msgid "
|
1569 |
msgstr ""
|
1570 |
|
1571 |
-
#: src/Tribe/
|
1572 |
-
msgid "
|
1573 |
msgstr ""
|
1574 |
|
1575 |
-
#: src/Tribe/
|
1576 |
-
msgid "
|
1577 |
msgstr ""
|
1578 |
|
1579 |
-
#: src/Tribe/
|
1580 |
-
msgid "
|
1581 |
msgstr ""
|
1582 |
|
1583 |
-
#: src/Tribe/
|
1584 |
-
msgid "
|
1585 |
msgstr ""
|
1586 |
|
1587 |
-
#: src/Tribe/
|
1588 |
-
msgid "
|
1589 |
msgstr ""
|
1590 |
|
1591 |
-
#: src/Tribe/
|
1592 |
-
msgid "
|
1593 |
msgstr ""
|
1594 |
|
1595 |
-
#: src/Tribe/
|
1596 |
-
msgid "
|
1597 |
msgstr ""
|
1598 |
|
1599 |
-
#: src/Tribe/
|
1600 |
-
msgid "
|
1601 |
msgstr ""
|
1602 |
|
1603 |
-
#: src/Tribe/
|
1604 |
-
msgid "
|
1605 |
msgstr ""
|
1606 |
|
1607 |
-
#: src/Tribe/
|
1608 |
-
msgid "
|
1609 |
msgstr ""
|
1610 |
|
1611 |
-
#: src/Tribe/
|
1612 |
-
msgid "
|
1613 |
msgstr ""
|
1614 |
|
1615 |
-
#: src/Tribe/
|
1616 |
-
msgid "
|
1617 |
msgstr ""
|
1618 |
|
1619 |
-
#: src/Tribe/
|
1620 |
-
msgid "
|
|
|
|
|
1621 |
msgstr ""
|
1622 |
|
1623 |
-
#: src/Tribe/
|
1624 |
-
msgid "
|
1625 |
msgstr ""
|
1626 |
|
1627 |
-
#: src/Tribe/
|
1628 |
-
msgid "
|
1629 |
msgstr ""
|
1630 |
|
1631 |
-
#: src/Tribe/
|
1632 |
-
msgid "
|
1633 |
msgstr ""
|
1634 |
|
1635 |
-
#: src/Tribe/
|
1636 |
-
msgid "
|
|
|
1637 |
msgstr ""
|
1638 |
|
1639 |
-
#: src/Tribe/
|
1640 |
-
msgid "
|
1641 |
msgstr ""
|
1642 |
|
1643 |
-
#: src/Tribe/
|
1644 |
-
msgid "
|
1645 |
msgstr ""
|
1646 |
|
1647 |
-
#: src/Tribe/
|
1648 |
-
msgid "
|
|
|
1649 |
msgstr ""
|
1650 |
|
1651 |
-
#: src/Tribe/
|
1652 |
-
msgid "
|
1653 |
msgstr ""
|
1654 |
|
1655 |
-
#: src/Tribe/
|
1656 |
-
msgid "
|
1657 |
msgstr ""
|
1658 |
|
1659 |
-
#: src/Tribe/
|
1660 |
-
msgid "
|
1661 |
msgstr ""
|
1662 |
|
1663 |
-
#: src/Tribe/
|
1664 |
-
msgid "
|
1665 |
msgstr ""
|
1666 |
|
1667 |
-
#: src/Tribe/
|
1668 |
-
msgid "
|
1669 |
msgstr ""
|
1670 |
|
1671 |
-
#: src/Tribe/
|
1672 |
-
msgid "
|
1673 |
msgstr ""
|
1674 |
|
1675 |
-
#: src/Tribe/
|
1676 |
-
msgid "
|
1677 |
msgstr ""
|
1678 |
|
1679 |
-
#: src/Tribe/
|
1680 |
-
msgid "
|
|
|
|
|
1681 |
msgstr ""
|
1682 |
|
1683 |
-
#: src/Tribe/
|
1684 |
-
msgid "
|
|
|
|
|
1685 |
msgstr ""
|
1686 |
|
1687 |
-
#: src/Tribe/
|
1688 |
-
msgid "
|
1689 |
msgstr ""
|
1690 |
|
1691 |
-
#: src/Tribe/
|
1692 |
-
msgid "
|
1693 |
msgstr ""
|
1694 |
|
1695 |
-
#: src/Tribe/
|
1696 |
-
msgid "
|
1697 |
msgstr ""
|
1698 |
|
1699 |
-
#: src/Tribe/
|
1700 |
-
msgid "
|
1701 |
msgstr ""
|
1702 |
|
1703 |
-
#: src/Tribe/
|
1704 |
-
msgid "
|
1705 |
msgstr ""
|
1706 |
|
1707 |
-
#: src/Tribe/
|
1708 |
-
msgid "
|
1709 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
1710 |
|
1711 |
-
#: src/Tribe/
|
1712 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1713 |
msgstr ""
|
1714 |
|
1715 |
-
#: src/Tribe/
|
1716 |
-
|
|
|
1717 |
msgstr ""
|
1718 |
|
1719 |
-
#: src/Tribe/
|
1720 |
-
msgid "
|
|
|
|
|
|
|
1721 |
msgstr ""
|
1722 |
|
1723 |
-
#: src/Tribe/
|
1724 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
1725 |
msgstr ""
|
1726 |
|
1727 |
-
#: src/Tribe/
|
1728 |
-
msgid "
|
|
|
|
|
|
|
|
|
1729 |
msgstr ""
|
1730 |
|
1731 |
-
#: src/Tribe/
|
1732 |
-
msgid "
|
|
|
|
|
|
|
|
|
1733 |
msgstr ""
|
1734 |
|
1735 |
-
#: src/Tribe/
|
1736 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
1737 |
msgstr ""
|
1738 |
|
1739 |
-
#: src/Tribe/
|
1740 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
1741 |
msgstr ""
|
1742 |
|
1743 |
-
#: src/Tribe/
|
1744 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
1745 |
msgstr ""
|
1746 |
|
1747 |
-
#: src/Tribe/
|
1748 |
-
msgid "
|
|
|
|
|
|
|
|
|
1749 |
msgstr ""
|
1750 |
|
1751 |
-
#: src/Tribe/
|
1752 |
-
|
|
|
1753 |
msgstr ""
|
1754 |
|
1755 |
-
#: src/Tribe/
|
1756 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
1757 |
msgstr ""
|
1758 |
|
1759 |
-
#: src/Tribe/
|
1760 |
-
msgid "
|
1761 |
msgstr ""
|
1762 |
|
1763 |
-
#: src/Tribe/
|
1764 |
-
msgid "
|
|
|
|
|
|
|
|
|
1765 |
msgstr ""
|
1766 |
|
1767 |
-
#: src/Tribe/
|
1768 |
-
|
|
|
1769 |
msgstr ""
|
1770 |
|
1771 |
-
#: src/Tribe/
|
1772 |
-
msgid "
|
1773 |
msgstr ""
|
1774 |
|
1775 |
-
#: src/Tribe/
|
1776 |
-
msgid "
|
1777 |
msgstr ""
|
1778 |
|
1779 |
-
#: src/Tribe/
|
1780 |
-
msgid "
|
1781 |
msgstr ""
|
1782 |
|
1783 |
-
#: src/Tribe/
|
1784 |
-
msgid "
|
1785 |
msgstr ""
|
1786 |
|
1787 |
-
#: src/Tribe/
|
1788 |
-
msgid "
|
1789 |
msgstr ""
|
1790 |
|
1791 |
-
#: src/Tribe/
|
1792 |
-
msgid "
|
1793 |
msgstr ""
|
1794 |
|
1795 |
-
#: src/Tribe/
|
1796 |
-
msgid "
|
1797 |
msgstr ""
|
1798 |
|
1799 |
-
#: src/Tribe/
|
1800 |
-
msgid "
|
1801 |
msgstr ""
|
1802 |
|
1803 |
-
#: src/Tribe/
|
1804 |
-
msgid "
|
1805 |
msgstr ""
|
1806 |
|
1807 |
-
#: src/Tribe/
|
1808 |
-
msgid "
|
1809 |
msgstr ""
|
1810 |
|
1811 |
-
#: src/Tribe/
|
1812 |
-
msgid "
|
1813 |
msgstr ""
|
1814 |
|
1815 |
-
#: src/Tribe/
|
1816 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1817 |
msgstr ""
|
1818 |
|
1819 |
-
#: src/Tribe/
|
1820 |
-
msgid "
|
1821 |
msgstr ""
|
1822 |
|
1823 |
-
#: src/Tribe/
|
1824 |
-
msgid "
|
1825 |
msgstr ""
|
1826 |
|
1827 |
-
#: src/Tribe/
|
1828 |
-
msgid "
|
1829 |
msgstr ""
|
1830 |
|
1831 |
-
#: src/Tribe/
|
1832 |
-
|
|
|
1833 |
msgstr ""
|
1834 |
|
1835 |
-
#: src/Tribe/
|
1836 |
-
msgid "
|
1837 |
msgstr ""
|
1838 |
|
1839 |
-
#: src/Tribe/
|
1840 |
-
msgid "
|
1841 |
msgstr ""
|
1842 |
|
1843 |
-
#: src/Tribe/
|
1844 |
-
msgid "
|
1845 |
msgstr ""
|
1846 |
|
1847 |
-
#: src/Tribe/
|
1848 |
-
msgid "
|
1849 |
msgstr ""
|
1850 |
|
1851 |
-
#: src/Tribe/
|
1852 |
-
msgid "
|
1853 |
msgstr ""
|
1854 |
|
1855 |
-
#: src/Tribe/
|
1856 |
-
msgid "
|
1857 |
msgstr ""
|
1858 |
|
1859 |
-
#: src/Tribe/
|
1860 |
-
msgid "
|
1861 |
msgstr ""
|
1862 |
|
1863 |
-
#: src/Tribe/
|
1864 |
-
msgid "
|
1865 |
msgstr ""
|
1866 |
|
1867 |
-
#: src/Tribe/
|
1868 |
-
msgid "
|
|
|
|
|
1869 |
msgstr ""
|
1870 |
|
1871 |
-
#: src/Tribe/
|
1872 |
-
msgid "
|
1873 |
msgstr ""
|
1874 |
|
1875 |
-
#: src/Tribe/
|
1876 |
-
msgid "
|
1877 |
msgstr ""
|
1878 |
|
1879 |
-
#: src/Tribe/
|
1880 |
-
msgid "
|
|
|
|
|
1881 |
msgstr ""
|
1882 |
|
1883 |
-
#: src/Tribe/
|
1884 |
-
msgid "
|
|
|
|
|
1885 |
msgstr ""
|
1886 |
|
1887 |
-
#: src/Tribe/
|
1888 |
-
msgid "
|
|
|
|
|
|
|
1889 |
msgstr ""
|
1890 |
|
1891 |
-
#: src/Tribe/
|
1892 |
-
msgid "
|
1893 |
msgstr ""
|
1894 |
|
1895 |
-
#: src/Tribe/
|
1896 |
-
msgid "
|
1897 |
msgstr ""
|
1898 |
|
1899 |
-
#: src/Tribe/
|
1900 |
-
msgid "
|
1901 |
msgstr ""
|
1902 |
|
1903 |
-
#: src/Tribe/
|
1904 |
-
msgid "
|
1905 |
msgstr ""
|
1906 |
|
1907 |
-
#: src/Tribe/
|
1908 |
-
|
|
|
1909 |
msgstr ""
|
1910 |
|
1911 |
-
#: src/Tribe/
|
1912 |
-
msgid "
|
1913 |
msgstr ""
|
1914 |
|
1915 |
-
#: src/Tribe/
|
1916 |
-
|
|
|
1917 |
msgstr ""
|
1918 |
|
1919 |
-
#: src/Tribe/
|
1920 |
-
msgid "
|
1921 |
msgstr ""
|
1922 |
|
1923 |
-
#: src/Tribe/
|
1924 |
-
msgid "
|
1925 |
msgstr ""
|
1926 |
|
1927 |
-
#: src/Tribe/
|
1928 |
-
msgid "
|
1929 |
msgstr ""
|
1930 |
|
1931 |
-
#: src/Tribe/
|
1932 |
-
msgid "
|
1933 |
msgstr ""
|
1934 |
|
1935 |
-
#: src/Tribe/
|
1936 |
-
msgid "
|
1937 |
msgstr ""
|
1938 |
|
1939 |
-
#: src/Tribe/
|
1940 |
-
msgid "
|
1941 |
msgstr ""
|
1942 |
|
1943 |
-
#: src/Tribe/
|
1944 |
-
msgid "
|
1945 |
msgstr ""
|
1946 |
|
1947 |
-
#: src/Tribe/
|
1948 |
-
msgid "
|
1949 |
msgstr ""
|
1950 |
|
1951 |
-
#: src/Tribe/
|
1952 |
-
msgid "
|
1953 |
msgstr ""
|
1954 |
|
1955 |
-
#: src/Tribe/
|
1956 |
-
|
|
|
1957 |
msgstr ""
|
1958 |
|
1959 |
-
#: src/Tribe/
|
1960 |
-
msgid "
|
|
|
|
|
1961 |
msgstr ""
|
1962 |
|
1963 |
-
#: src/Tribe/
|
1964 |
-
msgid "
|
1965 |
msgstr ""
|
1966 |
|
1967 |
-
#: src/Tribe/
|
1968 |
-
msgid "
|
1969 |
msgstr ""
|
1970 |
|
1971 |
-
#: src/Tribe/
|
1972 |
-
msgid "
|
1973 |
msgstr ""
|
1974 |
|
1975 |
-
#: src/Tribe/
|
1976 |
-
msgid "
|
1977 |
msgstr ""
|
1978 |
|
1979 |
-
#: src/Tribe/
|
1980 |
-
msgid "
|
|
|
1981 |
msgstr ""
|
1982 |
|
1983 |
-
#: src/Tribe/
|
1984 |
-
|
1985 |
-
msgid "None currently available"
|
1986 |
msgstr ""
|
1987 |
|
1988 |
-
#: src/Tribe/
|
1989 |
-
|
1990 |
-
msgid "None currently available"
|
1991 |
msgstr ""
|
1992 |
|
1993 |
-
#: src/Tribe/
|
1994 |
-
msgid "
|
1995 |
msgstr ""
|
1996 |
|
1997 |
-
#: src/Tribe/
|
1998 |
-
msgid "
|
|
|
|
|
1999 |
msgstr ""
|
2000 |
|
2001 |
-
#: src/Tribe/
|
2002 |
-
msgid "
|
2003 |
msgstr ""
|
2004 |
|
2005 |
-
#: src/Tribe/
|
2006 |
-
msgid "
|
2007 |
msgstr ""
|
2008 |
|
2009 |
-
#: src/
|
2010 |
-
msgid "
|
2011 |
msgstr ""
|
2012 |
|
2013 |
-
#: src/
|
2014 |
-
msgid "
|
2015 |
msgstr ""
|
2016 |
|
2017 |
-
#: src/
|
2018 |
-
msgid "
|
2019 |
msgstr ""
|
2020 |
|
2021 |
-
#: src/
|
2022 |
-
msgid "
|
2023 |
msgstr ""
|
2024 |
|
2025 |
-
#: src/
|
2026 |
-
msgid "
|
2027 |
msgstr ""
|
2028 |
|
2029 |
-
#: src/
|
2030 |
-
msgid "
|
2031 |
msgstr ""
|
2032 |
|
2033 |
-
#: src/
|
2034 |
-
msgid "
|
2035 |
msgstr ""
|
2036 |
|
2037 |
-
#: src/
|
2038 |
-
msgid "
|
2039 |
msgstr ""
|
2040 |
|
2041 |
-
#: src/
|
2042 |
-
msgid "
|
2043 |
msgstr ""
|
2044 |
|
2045 |
-
#: src/
|
2046 |
-
msgid "
|
2047 |
msgstr ""
|
2048 |
|
2049 |
-
#: src/
|
2050 |
-
msgid "
|
2051 |
msgstr ""
|
2052 |
|
2053 |
-
#: src/
|
2054 |
-
msgid "
|
|
|
|
|
|
|
2055 |
msgstr ""
|
2056 |
|
2057 |
-
#: src/
|
2058 |
-
msgid "
|
2059 |
msgstr ""
|
2060 |
|
2061 |
-
#: src/
|
2062 |
-
msgid "
|
2063 |
msgstr ""
|
2064 |
|
2065 |
-
#: src/
|
2066 |
-
msgid "
|
|
|
|
|
|
|
2067 |
msgstr ""
|
2068 |
|
2069 |
-
#: src/
|
2070 |
-
msgid "
|
|
|
|
|
|
|
|
|
2071 |
msgstr ""
|
2072 |
|
2073 |
-
#: src/
|
2074 |
-
msgid "
|
|
|
|
|
2075 |
msgstr ""
|
2076 |
|
2077 |
-
#: src/
|
2078 |
-
msgid "
|
2079 |
msgstr ""
|
2080 |
|
2081 |
-
#: src/
|
2082 |
-
msgid "
|
2083 |
msgstr ""
|
2084 |
|
2085 |
-
#: src/
|
2086 |
-
msgid "
|
|
|
|
|
|
|
|
|
2087 |
msgstr ""
|
2088 |
|
2089 |
-
#: src/
|
2090 |
-
msgid "
|
2091 |
msgstr ""
|
2092 |
|
2093 |
-
#: src/
|
2094 |
-
msgid "
|
2095 |
-
|
2096 |
-
msgstr[0] ""
|
2097 |
-
msgstr[1] ""
|
2098 |
-
|
2099 |
-
#: src/Tribe/PUE/Notices.php:270
|
2100 |
-
msgid "There is an update available for %1$s but your license has expired. %2$sVisit the Events Calendar website to renew your license.%3$s"
|
2101 |
-
msgid_plural "Updates are available for %1$s but your license keys have expired. %2$sVisit the Events Calendar website to renew your licenses.%3$s"
|
2102 |
-
msgstr[0] ""
|
2103 |
-
msgstr[1] ""
|
2104 |
|
2105 |
-
#: src/
|
2106 |
-
msgid "
|
2107 |
-
|
2108 |
-
msgstr[0] ""
|
2109 |
-
msgstr[1] ""
|
2110 |
|
2111 |
-
#: src/
|
2112 |
-
msgid "
|
|
|
|
|
|
|
|
|
2113 |
msgstr ""
|
2114 |
|
2115 |
-
#: src/
|
2116 |
-
|
2117 |
-
msgid "%1$s and %2$s"
|
2118 |
msgstr ""
|
2119 |
|
2120 |
-
#: src/
|
2121 |
-
msgid "
|
|
|
|
|
2122 |
msgstr ""
|
2123 |
|
2124 |
-
#: src/
|
2125 |
-
msgid "
|
2126 |
msgstr ""
|
2127 |
|
2128 |
-
#: src/
|
2129 |
-
msgid "
|
|
|
|
|
2130 |
msgstr ""
|
2131 |
|
2132 |
-
#: src/
|
2133 |
-
msgid "
|
2134 |
msgstr ""
|
2135 |
|
2136 |
-
#: src/
|
2137 |
-
msgid "
|
2138 |
msgstr ""
|
2139 |
|
2140 |
-
#: src/
|
2141 |
-
msgid "
|
2142 |
msgstr ""
|
2143 |
|
2144 |
-
#: src/
|
2145 |
-
msgid "
|
2146 |
msgstr ""
|
2147 |
|
2148 |
-
#: src/
|
2149 |
-
msgid "
|
2150 |
msgstr ""
|
2151 |
|
2152 |
-
#: src/
|
2153 |
-
|
2154 |
-
|
|
|
|
|
|
|
2155 |
msgstr ""
|
2156 |
|
2157 |
-
#: src/
|
2158 |
-
|
2159 |
-
|
|
|
2160 |
msgstr ""
|
2161 |
|
2162 |
-
#: src/
|
2163 |
-
msgid "
|
2164 |
msgstr ""
|
2165 |
|
2166 |
-
#: src/
|
2167 |
-
msgid "
|
|
|
|
|
|
|
2168 |
msgstr ""
|
2169 |
|
2170 |
-
#: src/
|
2171 |
-
msgid "
|
2172 |
msgstr ""
|
2173 |
|
2174 |
-
#: src/
|
2175 |
-
msgid "
|
|
|
|
|
|
|
|
|
2176 |
msgstr ""
|
2177 |
|
2178 |
-
#: src/
|
2179 |
-
msgid "
|
2180 |
msgstr ""
|
2181 |
|
2182 |
-
#: src/
|
2183 |
-
msgid "
|
|
|
|
|
2184 |
msgstr ""
|
2185 |
|
2186 |
-
#: src/
|
2187 |
-
msgid "
|
2188 |
msgstr ""
|
2189 |
|
2190 |
-
#: src/
|
2191 |
-
msgid "
|
2192 |
msgstr ""
|
2193 |
|
2194 |
-
#: src/
|
2195 |
-
msgid "
|
|
|
|
|
|
|
|
|
2196 |
msgstr ""
|
2197 |
|
2198 |
-
#: src/
|
2199 |
-
msgid "
|
2200 |
msgstr ""
|
2201 |
|
2202 |
-
#: src/
|
2203 |
-
msgid "
|
2204 |
msgstr ""
|
2205 |
|
2206 |
-
#: src/
|
2207 |
-
msgid "
|
2208 |
msgstr ""
|
2209 |
|
2210 |
-
#: src/
|
2211 |
-
msgid "
|
2212 |
msgstr ""
|
2213 |
|
2214 |
-
#: src/
|
2215 |
-
|
|
|
2216 |
msgstr ""
|
2217 |
|
2218 |
-
#: src/
|
2219 |
-
msgid "
|
|
|
|
|
|
|
|
|
2220 |
msgstr ""
|
2221 |
|
2222 |
-
#: src/
|
2223 |
-
msgid "
|
|
|
|
|
|
|
|
|
2224 |
msgstr ""
|
2225 |
|
2226 |
-
#: src/
|
2227 |
-
msgid "
|
|
|
|
|
|
|
2228 |
msgstr ""
|
2229 |
|
2230 |
-
#: src/
|
2231 |
-
msgid "
|
|
|
|
|
2232 |
msgstr ""
|
2233 |
|
2234 |
-
#: src/
|
2235 |
-
msgid "
|
|
|
|
|
2236 |
msgstr ""
|
2237 |
|
2238 |
-
#: src/
|
2239 |
-
msgid "
|
|
|
|
|
2240 |
msgstr ""
|
2241 |
|
2242 |
-
#: src/
|
2243 |
-
msgid "
|
2244 |
msgstr ""
|
2245 |
|
2246 |
-
#: src/
|
2247 |
-
msgid "
|
|
|
|
|
2248 |
msgstr ""
|
2249 |
|
2250 |
-
#: src/
|
2251 |
-
msgid "
|
2252 |
msgstr ""
|
2253 |
|
2254 |
-
#:
|
2255 |
-
msgid "
|
2256 |
msgstr ""
|
2257 |
|
2258 |
-
|
2259 |
-
msgid "
|
2260 |
msgstr ""
|
2261 |
|
2262 |
-
|
2263 |
-
msgid "
|
2264 |
msgstr ""
|
2265 |
|
2266 |
-
|
2267 |
-
msgid "
|
2268 |
msgstr ""
|
2269 |
|
2270 |
-
|
2271 |
-
msgid "
|
2272 |
msgstr ""
|
1 |
+
# Copyright (C) 2018 Modern Tribe
|
2 |
+
# This file is distributed under the same license as the Tribe Common package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: Tribe Common 4.7.12\n"
|
6 |
+
"Report-Msgid-Bugs-To: http://m.tri.be/191x\n"
|
7 |
+
"POT-Creation-Date: 2018-05-08 16:07:40+00:00\n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=UTF-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
11 |
+
"PO-Revision-Date: 2018-05-08 16:07\n"
|
12 |
+
"Last-Translator: \n"
|
13 |
+
"Language-Team: \n"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
|
15 |
+
#: src/Tribe/Admin/Activation_Page.php:84
|
16 |
+
msgid "Go to plugins page"
|
17 |
msgstr ""
|
18 |
|
19 |
+
#: src/Tribe/Admin/Activation_Page.php:84
|
20 |
+
msgid "Return to Plugins page"
|
21 |
msgstr ""
|
22 |
|
23 |
+
#: src/Tribe/Admin/Activation_Page.php:92
|
24 |
+
msgid "Go to WordPress Updates page"
|
25 |
msgstr ""
|
26 |
|
27 |
+
#: src/Tribe/Admin/Activation_Page.php:92
|
28 |
+
msgid "Return to WordPress Updates"
|
29 |
msgstr ""
|
30 |
|
31 |
+
#: src/Tribe/Admin/Help_Page.php:59 src/Tribe/Customizer.php:569
|
32 |
+
#: src/Tribe/Plugins_API.php:25
|
33 |
+
msgid "The Events Calendar"
|
34 |
msgstr ""
|
35 |
|
36 |
+
#: src/Tribe/Admin/Help_Page.php:63
|
37 |
+
msgid ""
|
38 |
+
"The Events Calendar is a carefully crafted, extensible plugin that lets you "
|
39 |
+
"easily share your events."
|
40 |
msgstr ""
|
41 |
|
42 |
+
#: src/Tribe/Admin/Help_Page.php:75 src/Tribe/Plugins_API.php:57
|
43 |
+
msgid "Event Tickets"
|
44 |
msgstr ""
|
45 |
|
46 |
+
#: src/Tribe/Admin/Help_Page.php:79
|
47 |
+
msgid ""
|
48 |
+
"Events Tickets is a carefully crafted, extensible plugin that lets you "
|
49 |
+
"easily sell tickets for your events."
|
50 |
msgstr ""
|
51 |
|
52 |
+
#: src/Tribe/Admin/Help_Page.php:91
|
53 |
+
msgid "Advanced Post Manager"
|
54 |
msgstr ""
|
55 |
|
56 |
+
#: src/Tribe/Admin/Help_Page.php:95
|
57 |
+
msgid ""
|
58 |
+
"Turbo charge your posts admin for any custom post type with sortable filters "
|
59 |
+
"and columns, and auto-registration of metaboxes."
|
60 |
msgstr ""
|
61 |
|
62 |
+
#: src/Tribe/Admin/Help_Page.php:170
|
63 |
+
msgid " and "
|
64 |
msgstr ""
|
65 |
|
66 |
+
#: src/Tribe/Admin/Help_Page.php:194 src/Tribe/Plugins_API.php:43
|
67 |
+
msgid "Events Calendar PRO"
|
68 |
msgstr ""
|
69 |
|
70 |
+
#: src/Tribe/Admin/Help_Page.php:203 src/Tribe/Plugins_API.php:111
|
71 |
+
msgid "Eventbrite Tickets"
|
72 |
msgstr ""
|
73 |
|
74 |
+
#: src/Tribe/Admin/Help_Page.php:211 src/Tribe/Plugins_API.php:90
|
75 |
+
msgid "Community Events"
|
76 |
msgstr ""
|
77 |
|
78 |
+
#: src/Tribe/Admin/Help_Page.php:219 src/Tribe/Plugins_API.php:34
|
79 |
+
msgid "Event Aggregator"
|
80 |
msgstr ""
|
81 |
|
82 |
+
#: src/Tribe/Admin/Help_Page.php:227 src/Tribe/Plugins_API.php:80
|
83 |
+
msgid "Filter Bar"
|
84 |
msgstr ""
|
85 |
|
86 |
+
#: src/Tribe/Admin/Help_Page.php:235 src/Tribe/Plugins_API.php:66
|
87 |
+
msgid "Event Tickets Plus"
|
88 |
msgstr ""
|
89 |
|
90 |
+
#: src/Tribe/Admin/Help_Page.php:244 src/Tribe/Plugins_API.php:100
|
91 |
+
msgid "Community Tickets"
|
92 |
msgstr ""
|
93 |
|
94 |
+
#: src/Tribe/Admin/Help_Page.php:405
|
95 |
+
msgctxt "not available"
|
96 |
+
msgid "n/a"
|
97 |
msgstr ""
|
98 |
|
99 |
+
#: src/Tribe/Admin/Help_Page.php:413
|
100 |
+
msgid "You need to upgrade!"
|
101 |
msgstr ""
|
102 |
|
103 |
+
#: src/Tribe/Admin/Help_Page.php:413 src/Tribe/Admin/Help_Page.php:788
|
104 |
+
msgid "You are up to date!"
|
105 |
msgstr ""
|
106 |
|
107 |
+
#: src/Tribe/Admin/Help_Page.php:778
|
108 |
+
msgid "Activate %s"
|
109 |
msgstr ""
|
110 |
|
111 |
+
#: src/Tribe/Admin/Help_Page.php:778
|
112 |
+
msgid "Activate Plugin"
|
113 |
msgstr ""
|
114 |
|
115 |
+
#: src/Tribe/Admin/Help_Page.php:786
|
116 |
+
msgid "Upgrade Plugin"
|
117 |
msgstr ""
|
118 |
|
119 |
+
#: src/Tribe/Admin/Help_Page.php:802
|
120 |
+
msgid "Install %s"
|
121 |
msgstr ""
|
122 |
|
123 |
+
#: src/Tribe/Admin/Help_Page.php:802
|
124 |
+
msgid "Install Plugin"
|
125 |
msgstr ""
|
126 |
|
127 |
+
#: src/Tribe/Admin/Help_Page.php:819
|
128 |
+
msgid "Latest Version:"
|
129 |
msgstr ""
|
130 |
|
131 |
+
#: src/Tribe/Admin/Help_Page.php:822 src/admin-views/app-shop.php:77
|
132 |
+
msgid "Requires:"
|
133 |
msgstr ""
|
134 |
|
135 |
+
#: src/Tribe/Admin/Help_Page.php:823
|
136 |
+
msgid "WordPress "
|
137 |
msgstr ""
|
138 |
|
139 |
+
#: src/Tribe/Admin/Help_Page.php:825
|
140 |
+
msgid "Active Users:"
|
141 |
msgstr ""
|
142 |
|
143 |
+
#: src/Tribe/Admin/Help_Page.php:828
|
144 |
+
msgid "Rating:"
|
145 |
msgstr ""
|
146 |
|
147 |
+
#: src/Tribe/Admin/Help_Page.php:847
|
148 |
+
msgid "Premium Add-Ons"
|
149 |
msgstr ""
|
150 |
|
151 |
+
#: src/Tribe/Admin/Help_Page.php:853
|
152 |
+
msgid "Plugin Active"
|
153 |
msgstr ""
|
154 |
|
155 |
+
#: src/Tribe/Admin/Help_Page.php:855
|
156 |
+
msgid "Plugin Inactive"
|
157 |
msgstr ""
|
158 |
|
159 |
+
#: src/Tribe/Admin/Help_Page.php:860
|
160 |
+
msgid "Visit the Add-on Page"
|
161 |
msgstr ""
|
162 |
|
163 |
+
#: src/Tribe/Admin/Notice/Plugin_Download.php:75
|
164 |
+
msgid ""
|
165 |
+
"To begin using %1$s, please install and activate the latest version of %2$s."
|
166 |
msgstr ""
|
167 |
|
168 |
+
#: src/Tribe/Admin/Notice/Plugin_Download.php:91
|
169 |
+
msgctxt "separator used in a list of items"
|
170 |
+
msgid ", "
|
171 |
msgstr ""
|
172 |
|
173 |
+
#: src/Tribe/Admin/Notice/Plugin_Download.php:92
|
174 |
+
msgctxt "the final separator in a list of two or more items"
|
175 |
+
msgid " and "
|
176 |
msgstr ""
|
177 |
|
178 |
+
#: src/Tribe/Ajax/Dropdown.php:38
|
179 |
+
msgid "Cannot look for Terms without a taxonomy"
|
180 |
msgstr ""
|
181 |
|
182 |
+
#: src/Tribe/Ajax/Dropdown.php:180
|
183 |
+
msgid "Missing data source for this dropdown"
|
184 |
msgstr ""
|
185 |
|
186 |
+
#: src/Tribe/Ajax/Dropdown.php:193
|
187 |
+
msgid "Empty data set for this dropdown"
|
188 |
msgstr ""
|
189 |
|
190 |
+
#: src/Tribe/Ajax/Dropdown.php:243
|
191 |
+
msgid "The \"%s\" source is invalid and cannot be reached on \"%s\" instance."
|
192 |
msgstr ""
|
193 |
|
194 |
+
#: src/Tribe/App_Shop.php:50 src/Tribe/App_Shop.php:51
|
195 |
+
#: src/Tribe/App_Shop.php:72
|
196 |
+
msgid "Event Add-Ons"
|
197 |
msgstr ""
|
198 |
|
199 |
+
#: src/Tribe/Cost_Utils.php:114
|
200 |
+
msgid "Free"
|
201 |
msgstr ""
|
202 |
|
203 |
+
#: src/Tribe/Credits.php:31
|
204 |
+
msgid "This calendar is powered by The Events Calendar."
|
205 |
msgstr ""
|
206 |
|
207 |
+
#: src/Tribe/Credits.php:55
|
208 |
+
msgid "Rate %1$sThe Events Calendar%2$s %3$s"
|
209 |
msgstr ""
|
210 |
|
211 |
+
#: src/Tribe/Credits.php:64
|
212 |
+
msgid "Rate %1$sEvent Tickets%2$s %3$s"
|
213 |
msgstr ""
|
214 |
|
215 |
+
#: src/Tribe/Customizer.php:570
|
216 |
+
msgid ""
|
217 |
+
"Use the following panel of your customizer to change the styling of your "
|
218 |
+
"Calendar and Event pages."
|
219 |
msgstr ""
|
220 |
|
221 |
+
#: src/Tribe/Documentation/Swagger/Cost_Details_Definition_Provider.php:24
|
222 |
+
msgid "The cost currency symbol"
|
223 |
msgstr ""
|
224 |
|
225 |
+
#: src/Tribe/Documentation/Swagger/Cost_Details_Definition_Provider.php:28
|
226 |
+
msgid "The position of the currency symbol in the cost string"
|
227 |
msgstr ""
|
228 |
|
229 |
+
#: src/Tribe/Documentation/Swagger/Cost_Details_Definition_Provider.php:34
|
230 |
+
msgid "A sorted array of all the numeric values for the cost"
|
231 |
msgstr ""
|
232 |
|
233 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:24
|
234 |
+
msgid "The date year"
|
235 |
msgstr ""
|
236 |
|
237 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:28
|
238 |
+
msgid "The date month"
|
239 |
msgstr ""
|
240 |
|
241 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:32
|
242 |
+
msgid "The date day"
|
243 |
msgstr ""
|
244 |
|
245 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:36
|
246 |
+
msgid "The date hour"
|
247 |
msgstr ""
|
248 |
|
249 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:40
|
250 |
+
msgid "The date minutes"
|
251 |
msgstr ""
|
252 |
|
253 |
+
#: src/Tribe/Documentation/Swagger/Date_Details_Definition_Provider.php:44
|
254 |
+
msgid "The date seconds"
|
255 |
msgstr ""
|
256 |
|
257 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:24
|
258 |
+
msgid "The URL to the full size version of the image"
|
259 |
msgstr ""
|
260 |
|
261 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:28
|
262 |
+
msgid "The image WordPress post ID"
|
263 |
msgstr ""
|
264 |
|
265 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:32
|
266 |
+
msgid "The image file extension"
|
267 |
msgstr ""
|
268 |
|
269 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:36
|
270 |
+
msgid "The image natural width in pixels"
|
271 |
msgstr ""
|
272 |
|
273 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:40
|
274 |
+
msgid "The image natural height in pixels"
|
275 |
msgstr ""
|
276 |
|
277 |
+
#: src/Tribe/Documentation/Swagger/Image_Definition_Provider.php:44
|
278 |
+
msgid "The details about each size available for the image"
|
279 |
msgstr ""
|
280 |
|
281 |
+
#: src/Tribe/Documentation/Swagger/Image_Size_Definition_Provider.php:24
|
282 |
+
msgid "The image width in pixels in the specified size"
|
283 |
msgstr ""
|
284 |
|
285 |
+
#: src/Tribe/Documentation/Swagger/Image_Size_Definition_Provider.php:28
|
286 |
+
msgid "The image height in pixels in the specified size"
|
287 |
msgstr ""
|
288 |
|
289 |
+
#: src/Tribe/Documentation/Swagger/Image_Size_Definition_Provider.php:32
|
290 |
+
msgid "The image mime-type"
|
291 |
msgstr ""
|
292 |
|
293 |
+
#: src/Tribe/Documentation/Swagger/Image_Size_Definition_Provider.php:36
|
294 |
+
msgid "The link to the image in the specified size on the site"
|
295 |
msgstr ""
|
296 |
|
297 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:24
|
298 |
+
msgid "The WordPress term ID"
|
299 |
msgstr ""
|
300 |
|
301 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:28
|
302 |
+
msgid "The term name"
|
303 |
msgstr ""
|
304 |
|
305 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:32
|
306 |
+
msgid "The term slug"
|
307 |
msgstr ""
|
308 |
|
309 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:36
|
310 |
+
msgid "The taxonomy the term belongs to"
|
311 |
msgstr ""
|
312 |
|
313 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:40
|
314 |
+
msgid "The term description"
|
315 |
msgstr ""
|
316 |
|
317 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:44
|
318 |
+
msgid "The term parent term if any"
|
319 |
msgstr ""
|
320 |
|
321 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:48
|
322 |
+
msgid "The number of posts associated with the term"
|
323 |
msgstr ""
|
324 |
|
325 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:52
|
326 |
+
msgid "The URL to the term archive page"
|
327 |
msgstr ""
|
328 |
|
329 |
+
#: src/Tribe/Documentation/Swagger/Term_Definition_Provider.php:57
|
330 |
+
msgid "A list of links to the term own, archive and parent REST URL"
|
331 |
msgstr ""
|
332 |
|
333 |
+
#: src/Tribe/Error.php:38
|
334 |
+
msgid "An Unknown error occurred"
|
335 |
msgstr ""
|
336 |
|
337 |
+
#: src/Tribe/Extension.php:144
|
338 |
+
msgid "Tutorial"
|
339 |
msgstr ""
|
340 |
|
341 |
+
#: src/Tribe/Extension.php:368
|
342 |
+
msgid ""
|
343 |
+
"Unable to run Tribe Extensions. Your website host is running PHP 5.2 or "
|
344 |
+
"older, and has likely disabled or misconfigured debug_backtrace(). You, or "
|
345 |
+
"your website host, will need to upgrade PHP or properly configure "
|
346 |
+
"debug_backtrace() for Tribe Extensions to work."
|
347 |
msgstr ""
|
348 |
|
349 |
+
#: src/Tribe/Field.php:231
|
350 |
+
msgid "Invalid field type specified"
|
351 |
msgstr ""
|
352 |
|
353 |
+
#: src/Tribe/Field.php:532
|
354 |
+
msgid "No radio options specified"
|
355 |
msgstr ""
|
356 |
|
357 |
+
#: src/Tribe/Field.php:568
|
358 |
+
msgid "No checkbox options specified"
|
359 |
msgstr ""
|
360 |
|
361 |
+
#: src/Tribe/Field.php:626
|
362 |
+
msgid "No select options specified"
|
363 |
msgstr ""
|
364 |
|
365 |
+
#: src/Tribe/Languages/Locations.php:55
|
366 |
+
msgid "United States"
|
367 |
msgstr ""
|
368 |
|
369 |
+
#: src/Tribe/Languages/Locations.php:56
|
370 |
+
msgid "Afghanistan"
|
371 |
msgstr ""
|
372 |
|
373 |
+
#: src/Tribe/Languages/Locations.php:57
|
374 |
+
msgid "Åland Islands"
|
375 |
msgstr ""
|
376 |
|
377 |
+
#: src/Tribe/Languages/Locations.php:58
|
378 |
+
msgid "Albania"
|
379 |
msgstr ""
|
380 |
|
381 |
+
#: src/Tribe/Languages/Locations.php:59
|
382 |
+
msgid "Algeria"
|
383 |
msgstr ""
|
384 |
|
385 |
+
#: src/Tribe/Languages/Locations.php:60
|
386 |
+
msgid "American Samoa"
|
387 |
msgstr ""
|
388 |
|
389 |
+
#: src/Tribe/Languages/Locations.php:61
|
390 |
+
msgid "Andorra"
|
391 |
msgstr ""
|
392 |
|
393 |
+
#: src/Tribe/Languages/Locations.php:62
|
394 |
+
msgid "Angola"
|
395 |
msgstr ""
|
396 |
|
397 |
+
#: src/Tribe/Languages/Locations.php:63
|
398 |
+
msgid "Anguilla"
|
399 |
msgstr ""
|
400 |
|
401 |
+
#: src/Tribe/Languages/Locations.php:64
|
402 |
+
msgid "Antarctica"
|
403 |
msgstr ""
|
404 |
|
405 |
+
#: src/Tribe/Languages/Locations.php:65
|
406 |
+
msgid "Antigua and Barbuda"
|
407 |
msgstr ""
|
408 |
|
409 |
+
#: src/Tribe/Languages/Locations.php:66
|
410 |
+
msgid "Argentina"
|
411 |
msgstr ""
|
412 |
|
413 |
+
#: src/Tribe/Languages/Locations.php:67
|
414 |
+
msgid "Armenia"
|
415 |
msgstr ""
|
416 |
|
417 |
+
#: src/Tribe/Languages/Locations.php:68
|
418 |
+
msgid "Aruba"
|
419 |
msgstr ""
|
420 |
|
421 |
+
#: src/Tribe/Languages/Locations.php:69
|
422 |
+
msgid "Australia"
|
423 |
msgstr ""
|
424 |
|
425 |
+
#: src/Tribe/Languages/Locations.php:70
|
426 |
+
msgid "Austria"
|
427 |
msgstr ""
|
428 |
|
429 |
+
#: src/Tribe/Languages/Locations.php:71
|
430 |
+
msgid "Azerbaijan"
|
431 |
msgstr ""
|
432 |
|
433 |
+
#: src/Tribe/Languages/Locations.php:72
|
434 |
+
msgid "Bahamas"
|
435 |
msgstr ""
|
436 |
|
437 |
+
#: src/Tribe/Languages/Locations.php:73
|
438 |
+
msgid "Bahrain"
|
439 |
msgstr ""
|
440 |
|
441 |
+
#: src/Tribe/Languages/Locations.php:74
|
442 |
+
msgid "Bangladesh"
|
443 |
msgstr ""
|
444 |
|
445 |
+
#: src/Tribe/Languages/Locations.php:75
|
446 |
+
msgid "Barbados"
|
447 |
msgstr ""
|
448 |
|
449 |
+
#: src/Tribe/Languages/Locations.php:76
|
450 |
+
msgid "Belarus"
|
451 |
msgstr ""
|
452 |
|
453 |
+
#: src/Tribe/Languages/Locations.php:77
|
454 |
+
msgid "Belgium"
|
455 |
msgstr ""
|
456 |
|
457 |
+
#: src/Tribe/Languages/Locations.php:78
|
458 |
+
msgid "Belize"
|
459 |
msgstr ""
|
460 |
|
461 |
+
#: src/Tribe/Languages/Locations.php:79
|
462 |
+
msgid "Benin"
|
463 |
msgstr ""
|
464 |
|
465 |
+
#: src/Tribe/Languages/Locations.php:80
|
466 |
+
msgid "Bermuda"
|
467 |
msgstr ""
|
468 |
|
469 |
+
#: src/Tribe/Languages/Locations.php:81
|
470 |
+
msgid "Bhutan"
|
471 |
msgstr ""
|
472 |
|
473 |
+
#: src/Tribe/Languages/Locations.php:82
|
474 |
+
msgid "Bolivia"
|
475 |
msgstr ""
|
476 |
|
477 |
+
#: src/Tribe/Languages/Locations.php:83
|
478 |
+
msgid "Bosnia and Herzegowina"
|
479 |
msgstr ""
|
480 |
|
481 |
+
#: src/Tribe/Languages/Locations.php:84
|
482 |
+
msgid "Botswana"
|
|
|
483 |
msgstr ""
|
484 |
|
485 |
+
#: src/Tribe/Languages/Locations.php:85
|
486 |
+
msgid "Bouvet Island"
|
487 |
msgstr ""
|
488 |
|
489 |
+
#: src/Tribe/Languages/Locations.php:86
|
490 |
+
msgid "Brazil"
|
491 |
msgstr ""
|
492 |
|
493 |
+
#: src/Tribe/Languages/Locations.php:87
|
494 |
+
msgid "British Indian Ocean Territory"
|
495 |
msgstr ""
|
496 |
|
497 |
+
#: src/Tribe/Languages/Locations.php:88
|
498 |
+
msgid "Brunei Darussalam"
|
499 |
msgstr ""
|
500 |
|
501 |
+
#: src/Tribe/Languages/Locations.php:89
|
502 |
+
msgid "Bulgaria"
|
503 |
msgstr ""
|
504 |
|
505 |
+
#: src/Tribe/Languages/Locations.php:90
|
506 |
+
msgid "Burkina Faso"
|
507 |
msgstr ""
|
508 |
|
509 |
+
#: src/Tribe/Languages/Locations.php:91
|
510 |
+
msgid "Burundi"
|
511 |
msgstr ""
|
512 |
|
513 |
+
#: src/Tribe/Languages/Locations.php:92
|
514 |
+
msgid "Cambodia"
|
515 |
msgstr ""
|
516 |
|
517 |
+
#: src/Tribe/Languages/Locations.php:93
|
518 |
+
msgid "Cameroon"
|
519 |
msgstr ""
|
520 |
|
521 |
+
#: src/Tribe/Languages/Locations.php:94
|
522 |
+
msgid "Canada"
|
523 |
msgstr ""
|
524 |
|
525 |
+
#: src/Tribe/Languages/Locations.php:95
|
526 |
+
msgid "Cape Verde"
|
527 |
msgstr ""
|
528 |
|
529 |
+
#: src/Tribe/Languages/Locations.php:96
|
530 |
+
msgid "Cayman Islands"
|
531 |
msgstr ""
|
532 |
|
533 |
+
#: src/Tribe/Languages/Locations.php:97
|
534 |
+
msgid "Central African Republic"
|
535 |
msgstr ""
|
536 |
|
537 |
+
#: src/Tribe/Languages/Locations.php:98
|
538 |
+
msgid "Chad"
|
539 |
msgstr ""
|
540 |
|
541 |
+
#: src/Tribe/Languages/Locations.php:99
|
542 |
+
msgid "Chile"
|
543 |
msgstr ""
|
544 |
|
545 |
+
#: src/Tribe/Languages/Locations.php:100
|
546 |
+
msgid "China"
|
547 |
+
msgstr ""
|
|
|
|
|
548 |
|
549 |
+
#: src/Tribe/Languages/Locations.php:101
|
550 |
+
msgid "Christmas Island"
|
551 |
msgstr ""
|
552 |
|
553 |
+
#: src/Tribe/Languages/Locations.php:102
|
554 |
+
msgid "Cocos (Keeling) Islands"
|
555 |
msgstr ""
|
556 |
|
557 |
+
#: src/Tribe/Languages/Locations.php:103
|
558 |
+
msgid "Collectivity of Saint Martin"
|
559 |
msgstr ""
|
560 |
|
561 |
+
#: src/Tribe/Languages/Locations.php:104
|
562 |
+
msgid "Colombia"
|
563 |
msgstr ""
|
564 |
|
565 |
+
#: src/Tribe/Languages/Locations.php:105
|
566 |
+
msgid "Comoros"
|
567 |
msgstr ""
|
568 |
|
569 |
+
#: src/Tribe/Languages/Locations.php:106
|
570 |
+
msgid "Congo"
|
571 |
msgstr ""
|
572 |
|
573 |
+
#: src/Tribe/Languages/Locations.php:107
|
574 |
+
msgid "Congo, Democratic Republic of the"
|
575 |
msgstr ""
|
576 |
|
577 |
+
#: src/Tribe/Languages/Locations.php:108
|
578 |
+
msgid "Cook Islands"
|
579 |
msgstr ""
|
580 |
|
581 |
+
#: src/Tribe/Languages/Locations.php:109
|
582 |
+
msgid "Costa Rica"
|
583 |
msgstr ""
|
584 |
|
585 |
+
#: src/Tribe/Languages/Locations.php:110
|
586 |
+
msgid "Côte d'Ivoire"
|
587 |
msgstr ""
|
588 |
|
589 |
+
#: src/Tribe/Languages/Locations.php:111
|
590 |
+
msgid "Croatia (Local Name: Hrvatska)"
|
591 |
msgstr ""
|
592 |
|
593 |
+
#: src/Tribe/Languages/Locations.php:112
|
594 |
+
msgid "Cuba"
|
595 |
msgstr ""
|
596 |
|
597 |
+
#: src/Tribe/Languages/Locations.php:113
|
598 |
+
msgid "Curaçao"
|
599 |
msgstr ""
|
600 |
|
601 |
+
#: src/Tribe/Languages/Locations.php:114
|
602 |
+
msgid "Cyprus"
|
603 |
msgstr ""
|
604 |
|
605 |
+
#: src/Tribe/Languages/Locations.php:115
|
606 |
+
msgid "Czech Republic"
|
607 |
msgstr ""
|
608 |
|
609 |
+
#: src/Tribe/Languages/Locations.php:116
|
610 |
+
msgid "Denmark"
|
611 |
msgstr ""
|
612 |
|
613 |
+
#: src/Tribe/Languages/Locations.php:117
|
614 |
+
msgid "Djibouti"
|
615 |
msgstr ""
|
616 |
|
617 |
+
#: src/Tribe/Languages/Locations.php:118
|
618 |
+
msgid "Dominica"
|
|
|
619 |
msgstr ""
|
620 |
|
621 |
+
#: src/Tribe/Languages/Locations.php:119
|
622 |
+
msgid "Dominican Republic"
|
623 |
msgstr ""
|
624 |
|
625 |
+
#: src/Tribe/Languages/Locations.php:120
|
626 |
+
msgid "East Timor"
|
627 |
msgstr ""
|
628 |
|
629 |
+
#: src/Tribe/Languages/Locations.php:121
|
630 |
+
msgid "Ecuador"
|
631 |
msgstr ""
|
632 |
|
633 |
+
#: src/Tribe/Languages/Locations.php:122
|
634 |
+
msgid "Egypt"
|
635 |
msgstr ""
|
636 |
|
637 |
+
#: src/Tribe/Languages/Locations.php:123
|
638 |
+
msgid "El Salvador"
|
639 |
msgstr ""
|
640 |
|
641 |
+
#: src/Tribe/Languages/Locations.php:124
|
642 |
+
msgid "Equatorial Guinea"
|
643 |
msgstr ""
|
644 |
|
645 |
+
#: src/Tribe/Languages/Locations.php:125
|
646 |
+
msgid "Eritrea"
|
647 |
msgstr ""
|
648 |
|
649 |
+
#: src/Tribe/Languages/Locations.php:126
|
650 |
+
msgid "Estonia"
|
651 |
msgstr ""
|
652 |
|
653 |
+
#: src/Tribe/Languages/Locations.php:127
|
654 |
+
msgid "Ethiopia"
|
655 |
msgstr ""
|
656 |
|
657 |
+
#: src/Tribe/Languages/Locations.php:128
|
658 |
+
msgid "Falkland Islands (Malvinas)"
|
659 |
msgstr ""
|
660 |
|
661 |
+
#: src/Tribe/Languages/Locations.php:129
|
662 |
+
msgid "Faroe Islands"
|
663 |
msgstr ""
|
664 |
|
665 |
+
#: src/Tribe/Languages/Locations.php:130
|
666 |
+
msgid "Fiji"
|
667 |
msgstr ""
|
668 |
|
669 |
+
#: src/Tribe/Languages/Locations.php:131
|
670 |
+
msgid "Finland"
|
671 |
msgstr ""
|
672 |
|
673 |
+
#: src/Tribe/Languages/Locations.php:132
|
674 |
+
msgid "France"
|
675 |
msgstr ""
|
676 |
|
677 |
+
#: src/Tribe/Languages/Locations.php:133
|
678 |
+
msgid "French Guiana"
|
679 |
msgstr ""
|
680 |
|
681 |
+
#: src/Tribe/Languages/Locations.php:134
|
682 |
+
msgid "French Polynesia"
|
683 |
msgstr ""
|
684 |
|
685 |
+
#: src/Tribe/Languages/Locations.php:135
|
686 |
+
msgid "French Southern Territories"
|
687 |
msgstr ""
|
688 |
|
689 |
+
#: src/Tribe/Languages/Locations.php:136
|
690 |
+
msgid "Gabon"
|
691 |
msgstr ""
|
692 |
|
693 |
+
#: src/Tribe/Languages/Locations.php:137
|
694 |
+
msgid "Gambia"
|
695 |
msgstr ""
|
696 |
|
697 |
+
#: src/Tribe/Languages/Locations.php:138 src/Tribe/Languages/Locations.php:334
|
698 |
+
msgid "Georgia"
|
699 |
msgstr ""
|
700 |
|
701 |
+
#: src/Tribe/Languages/Locations.php:139
|
702 |
+
msgid "Germany"
|
703 |
msgstr ""
|
704 |
|
705 |
+
#: src/Tribe/Languages/Locations.php:140
|
706 |
+
msgid "Ghana"
|
707 |
msgstr ""
|
708 |
|
709 |
+
#: src/Tribe/Languages/Locations.php:141
|
710 |
+
msgid "Gibraltar"
|
711 |
msgstr ""
|
712 |
|
713 |
+
#: src/Tribe/Languages/Locations.php:142
|
714 |
+
msgid "Greece"
|
715 |
msgstr ""
|
716 |
|
717 |
+
#: src/Tribe/Languages/Locations.php:143
|
718 |
+
msgid "Greenland"
|
719 |
msgstr ""
|
720 |
|
721 |
+
#: src/Tribe/Languages/Locations.php:144
|
722 |
+
msgid "Grenada"
|
723 |
msgstr ""
|
724 |
|
725 |
+
#: src/Tribe/Languages/Locations.php:145
|
726 |
+
msgid "Guadeloupe"
|
727 |
msgstr ""
|
728 |
|
729 |
+
#: src/Tribe/Languages/Locations.php:146
|
730 |
+
msgid "Guam"
|
731 |
msgstr ""
|
732 |
|
733 |
+
#: src/Tribe/Languages/Locations.php:147
|
734 |
+
msgid "Guatemala"
|
735 |
msgstr ""
|
736 |
|
737 |
+
#: src/Tribe/Languages/Locations.php:148
|
738 |
+
msgid "Guinea"
|
|
|
739 |
msgstr ""
|
740 |
|
741 |
+
#: src/Tribe/Languages/Locations.php:149
|
742 |
+
msgid "Guinea-Bissau"
|
743 |
msgstr ""
|
744 |
|
745 |
+
#: src/Tribe/Languages/Locations.php:150
|
746 |
+
msgid "Guyana"
|
747 |
msgstr ""
|
748 |
|
749 |
+
#: src/Tribe/Languages/Locations.php:151
|
750 |
+
msgid "Haiti"
|
751 |
msgstr ""
|
752 |
|
753 |
+
#: src/Tribe/Languages/Locations.php:152
|
754 |
+
msgid "Heard and McDonald Islands"
|
755 |
msgstr ""
|
756 |
|
757 |
+
#: src/Tribe/Languages/Locations.php:153
|
758 |
+
msgid "Holy See (Vatican City State)"
|
759 |
msgstr ""
|
760 |
|
761 |
+
#: src/Tribe/Languages/Locations.php:154
|
762 |
+
msgid "Honduras"
|
763 |
msgstr ""
|
764 |
|
765 |
+
#: src/Tribe/Languages/Locations.php:155
|
766 |
+
msgid "Hong Kong"
|
767 |
msgstr ""
|
768 |
|
769 |
+
#: src/Tribe/Languages/Locations.php:156
|
770 |
+
msgid "Hungary"
|
771 |
msgstr ""
|
772 |
|
773 |
+
#: src/Tribe/Languages/Locations.php:157
|
774 |
+
msgid "Iceland"
|
775 |
msgstr ""
|
776 |
|
777 |
+
#: src/Tribe/Languages/Locations.php:158
|
778 |
+
msgid "India"
|
779 |
msgstr ""
|
780 |
|
781 |
+
#: src/Tribe/Languages/Locations.php:159
|
782 |
+
msgid "Indonesia"
|
783 |
msgstr ""
|
784 |
|
785 |
+
#: src/Tribe/Languages/Locations.php:160
|
786 |
+
msgid "Iran, Islamic Republic of"
|
787 |
msgstr ""
|
788 |
|
789 |
+
#: src/Tribe/Languages/Locations.php:161
|
790 |
+
msgid "Iraq"
|
791 |
msgstr ""
|
792 |
|
793 |
+
#: src/Tribe/Languages/Locations.php:162
|
794 |
+
msgid "Ireland"
|
795 |
msgstr ""
|
796 |
|
797 |
+
#: src/Tribe/Languages/Locations.php:163
|
798 |
+
msgid "Israel"
|
799 |
msgstr ""
|
800 |
|
801 |
+
#: src/Tribe/Languages/Locations.php:164
|
802 |
+
msgid "Italy"
|
803 |
msgstr ""
|
804 |
|
805 |
+
#: src/Tribe/Languages/Locations.php:165
|
806 |
+
msgid "Jamaica"
|
807 |
msgstr ""
|
808 |
|
809 |
+
#: src/Tribe/Languages/Locations.php:166
|
810 |
+
msgid "Japan"
|
811 |
msgstr ""
|
812 |
|
813 |
+
#: src/Tribe/Languages/Locations.php:167
|
814 |
+
msgid "Jordan"
|
815 |
msgstr ""
|
816 |
|
817 |
+
#: src/Tribe/Languages/Locations.php:168
|
818 |
+
msgid "Kazakhstan"
|
819 |
msgstr ""
|
820 |
|
821 |
+
#: src/Tribe/Languages/Locations.php:169
|
822 |
+
msgid "Kenya"
|
823 |
msgstr ""
|
824 |
|
825 |
+
#: src/Tribe/Languages/Locations.php:170
|
826 |
+
msgid "Kiribati"
|
827 |
msgstr ""
|
828 |
|
829 |
+
#: src/Tribe/Languages/Locations.php:171
|
830 |
+
msgid "Korea, Democratic People's Republic of"
|
831 |
msgstr ""
|
832 |
|
833 |
+
#: src/Tribe/Languages/Locations.php:172
|
834 |
+
msgid "Korea, Republic of"
|
835 |
msgstr ""
|
836 |
|
837 |
+
#: src/Tribe/Languages/Locations.php:173
|
838 |
+
msgid "Kuwait"
|
839 |
msgstr ""
|
840 |
|
841 |
+
#: src/Tribe/Languages/Locations.php:174
|
842 |
+
msgid "Kyrgyzstan"
|
843 |
msgstr ""
|
844 |
|
845 |
+
#: src/Tribe/Languages/Locations.php:175
|
846 |
+
msgid "Lao People's Democratic Republic"
|
847 |
msgstr ""
|
848 |
|
849 |
+
#: src/Tribe/Languages/Locations.php:176
|
850 |
+
msgid "Latvia"
|
851 |
msgstr ""
|
852 |
|
853 |
+
#: src/Tribe/Languages/Locations.php:177
|
854 |
+
msgid "Lebanon"
|
855 |
msgstr ""
|
856 |
|
857 |
+
#: src/Tribe/Languages/Locations.php:178
|
858 |
+
msgid "Lesotho"
|
859 |
msgstr ""
|
860 |
|
861 |
+
#: src/Tribe/Languages/Locations.php:179
|
862 |
+
msgid "Liberia"
|
863 |
msgstr ""
|
864 |
|
865 |
+
#: src/Tribe/Languages/Locations.php:180
|
866 |
+
msgid "Libya"
|
867 |
msgstr ""
|
868 |
|
869 |
+
#: src/Tribe/Languages/Locations.php:181
|
870 |
+
msgid "Liechtenstein"
|
871 |
msgstr ""
|
872 |
|
873 |
+
#: src/Tribe/Languages/Locations.php:182
|
874 |
+
msgid "Lithuania"
|
875 |
msgstr ""
|
876 |
|
877 |
+
#: src/Tribe/Languages/Locations.php:183
|
878 |
+
msgid "Luxembourg"
|
879 |
msgstr ""
|
880 |
|
881 |
+
#: src/Tribe/Languages/Locations.php:184
|
882 |
+
msgid "Macau"
|
883 |
msgstr ""
|
884 |
|
885 |
+
#: src/Tribe/Languages/Locations.php:185
|
886 |
+
msgid "Macedonia"
|
887 |
msgstr ""
|
888 |
|
889 |
+
#: src/Tribe/Languages/Locations.php:186
|
890 |
+
msgid "Madagascar"
|
891 |
msgstr ""
|
892 |
|
893 |
+
#: src/Tribe/Languages/Locations.php:187
|
894 |
+
msgid "Malawi"
|
895 |
msgstr ""
|
896 |
|
897 |
+
#: src/Tribe/Languages/Locations.php:188
|
898 |
+
msgid "Malaysia"
|
899 |
msgstr ""
|
900 |
|
901 |
+
#: src/Tribe/Languages/Locations.php:189
|
902 |
+
msgid "Maldives"
|
903 |
msgstr ""
|
904 |
|
905 |
+
#: src/Tribe/Languages/Locations.php:190
|
906 |
+
msgid "Mali"
|
907 |
msgstr ""
|
908 |
|
909 |
+
#: src/Tribe/Languages/Locations.php:191
|
910 |
+
msgid "Malta"
|
911 |
msgstr ""
|
912 |
|
913 |
+
#: src/Tribe/Languages/Locations.php:192
|
914 |
+
msgid "Marshall Islands"
|
915 |
msgstr ""
|
916 |
|
917 |
+
#: src/Tribe/Languages/Locations.php:193
|
918 |
+
msgid "Martinique"
|
919 |
msgstr ""
|
920 |
|
921 |
+
#: src/Tribe/Languages/Locations.php:194
|
922 |
+
msgid "Mauritania"
|
923 |
msgstr ""
|
924 |
|
925 |
+
#: src/Tribe/Languages/Locations.php:195
|
926 |
+
msgid "Mauritius"
|
927 |
msgstr ""
|
928 |
|
929 |
+
#: src/Tribe/Languages/Locations.php:196
|
930 |
+
msgid "Mayotte"
|
931 |
msgstr ""
|
932 |
|
933 |
+
#: src/Tribe/Languages/Locations.php:197
|
934 |
+
msgid "Mexico"
|
935 |
msgstr ""
|
936 |
|
937 |
+
#: src/Tribe/Languages/Locations.php:198
|
938 |
+
msgid "Micronesia, Federated States of"
|
939 |
msgstr ""
|
940 |
|
941 |
+
#: src/Tribe/Languages/Locations.php:199
|
942 |
+
msgid "Moldova, Republic of"
|
943 |
msgstr ""
|
944 |
|
945 |
+
#: src/Tribe/Languages/Locations.php:200
|
946 |
+
msgid "Monaco"
|
947 |
msgstr ""
|
948 |
|
949 |
+
#: src/Tribe/Languages/Locations.php:201
|
950 |
+
msgid "Mongolia"
|
951 |
msgstr ""
|
952 |
|
953 |
+
#: src/Tribe/Languages/Locations.php:202
|
954 |
+
msgid "Montenegro"
|
955 |
msgstr ""
|
956 |
|
957 |
+
#: src/Tribe/Languages/Locations.php:203
|
958 |
+
msgid "Montserrat"
|
959 |
msgstr ""
|
960 |
|
961 |
+
#: src/Tribe/Languages/Locations.php:204
|
962 |
+
msgid "Morocco"
|
963 |
msgstr ""
|
964 |
|
965 |
+
#: src/Tribe/Languages/Locations.php:205
|
966 |
+
msgid "Mozambique"
|
967 |
msgstr ""
|
968 |
|
969 |
+
#: src/Tribe/Languages/Locations.php:206
|
970 |
+
msgid "Myanmar"
|
971 |
msgstr ""
|
972 |
|
973 |
+
#: src/Tribe/Languages/Locations.php:207
|
974 |
+
msgid "Namibia"
|
975 |
msgstr ""
|
976 |
|
977 |
+
#: src/Tribe/Languages/Locations.php:208
|
978 |
+
msgid "Nauru"
|
979 |
msgstr ""
|
980 |
|
981 |
+
#: src/Tribe/Languages/Locations.php:209
|
982 |
+
msgid "Nepal"
|
983 |
msgstr ""
|
984 |
|
985 |
+
#: src/Tribe/Languages/Locations.php:210
|
986 |
+
msgid "Netherlands"
|
987 |
msgstr ""
|
988 |
|
989 |
+
#: src/Tribe/Languages/Locations.php:211
|
990 |
+
msgid "New Caledonia"
|
991 |
msgstr ""
|
992 |
|
993 |
+
#: src/Tribe/Languages/Locations.php:212
|
994 |
+
msgid "New Zealand"
|
995 |
msgstr ""
|
996 |
|
997 |
+
#: src/Tribe/Languages/Locations.php:213
|
998 |
+
msgid "Nicaragua"
|
999 |
msgstr ""
|
1000 |
|
1001 |
+
#: src/Tribe/Languages/Locations.php:214
|
1002 |
+
msgid "Niger"
|
1003 |
msgstr ""
|
1004 |
|
1005 |
+
#: src/Tribe/Languages/Locations.php:215
|
1006 |
+
msgid "Nigeria"
|
1007 |
msgstr ""
|
1008 |
|
1009 |
+
#: src/Tribe/Languages/Locations.php:216
|
1010 |
+
msgid "Niue"
|
1011 |
msgstr ""
|
1012 |
|
1013 |
+
#: src/Tribe/Languages/Locations.php:217
|
1014 |
+
msgid "Norfolk Island"
|
1015 |
msgstr ""
|
1016 |
|
1017 |
+
#: src/Tribe/Languages/Locations.php:218
|
1018 |
+
msgid "Northern Mariana Islands"
|
1019 |
msgstr ""
|
1020 |
|
1021 |
+
#: src/Tribe/Languages/Locations.php:219
|
1022 |
+
msgid "Norway"
|
1023 |
msgstr ""
|
1024 |
|
1025 |
+
#: src/Tribe/Languages/Locations.php:220
|
1026 |
+
msgid "Oman"
|
1027 |
msgstr ""
|
1028 |
|
1029 |
+
#: src/Tribe/Languages/Locations.php:221
|
1030 |
+
msgid "Pakistan"
|
1031 |
msgstr ""
|
1032 |
|
1033 |
+
#: src/Tribe/Languages/Locations.php:222
|
1034 |
+
msgid "Palau"
|
1035 |
msgstr ""
|
1036 |
|
1037 |
+
#: src/Tribe/Languages/Locations.php:223
|
1038 |
+
msgid "Panama"
|
1039 |
msgstr ""
|
1040 |
|
1041 |
+
#: src/Tribe/Languages/Locations.php:224
|
1042 |
+
msgid "Papua New Guinea"
|
1043 |
msgstr ""
|
1044 |
|
1045 |
+
#: src/Tribe/Languages/Locations.php:225
|
1046 |
+
msgid "Paraguay"
|
1047 |
msgstr ""
|
1048 |
|
1049 |
+
#: src/Tribe/Languages/Locations.php:226
|
1050 |
+
msgid "Peru"
|
1051 |
msgstr ""
|
1052 |
|
1053 |
+
#: src/Tribe/Languages/Locations.php:227
|
1054 |
+
msgid "Philippines"
|
1055 |
msgstr ""
|
1056 |
|
1057 |
+
#: src/Tribe/Languages/Locations.php:228
|
1058 |
+
msgid "Pitcairn"
|
1059 |
msgstr ""
|
1060 |
|
1061 |
+
#: src/Tribe/Languages/Locations.php:229
|
1062 |
+
msgid "Poland"
|
1063 |
msgstr ""
|
1064 |
|
1065 |
+
#: src/Tribe/Languages/Locations.php:230
|
1066 |
+
msgid "Portugal"
|
1067 |
msgstr ""
|
1068 |
|
1069 |
+
#: src/Tribe/Languages/Locations.php:231
|
1070 |
+
msgid "Puerto Rico"
|
1071 |
msgstr ""
|
1072 |
|
1073 |
+
#: src/Tribe/Languages/Locations.php:232
|
1074 |
+
msgid "Qatar"
|
1075 |
msgstr ""
|
1076 |
|
1077 |
+
#: src/Tribe/Languages/Locations.php:233
|
1078 |
+
msgid "Reunion"
|
1079 |
msgstr ""
|
1080 |
|
1081 |
+
#: src/Tribe/Languages/Locations.php:234
|
1082 |
+
msgid "Romania"
|
1083 |
msgstr ""
|
1084 |
|
1085 |
+
#: src/Tribe/Languages/Locations.php:235
|
1086 |
+
msgid "Russian Federation"
|
1087 |
msgstr ""
|
1088 |
|
1089 |
+
#: src/Tribe/Languages/Locations.php:236
|
1090 |
+
msgid "Rwanda"
|
1091 |
msgstr ""
|
1092 |
|
1093 |
+
#: src/Tribe/Languages/Locations.php:237
|
1094 |
+
msgid "Saint Barthélemy"
|
1095 |
msgstr ""
|
1096 |
|
1097 |
+
#: src/Tribe/Languages/Locations.php:238
|
1098 |
+
msgid "Saint Helena"
|
1099 |
msgstr ""
|
1100 |
|
1101 |
+
#: src/Tribe/Languages/Locations.php:239
|
1102 |
+
msgid "Saint Kitts and Nevis"
|
1103 |
msgstr ""
|
1104 |
|
1105 |
+
#: src/Tribe/Languages/Locations.php:240
|
1106 |
+
msgid "Saint Lucia"
|
1107 |
msgstr ""
|
1108 |
|
1109 |
+
#: src/Tribe/Languages/Locations.php:241
|
1110 |
+
msgid "Saint Pierre and Miquelon"
|
1111 |
msgstr ""
|
1112 |
|
1113 |
+
#: src/Tribe/Languages/Locations.php:242
|
1114 |
+
msgid "Saint Vincent and The Grenadines"
|
1115 |
msgstr ""
|
1116 |
|
1117 |
+
#: src/Tribe/Languages/Locations.php:243
|
1118 |
+
msgid "Samoa"
|
1119 |
msgstr ""
|
1120 |
|
1121 |
+
#: src/Tribe/Languages/Locations.php:244
|
1122 |
+
msgid "San Marino"
|
1123 |
msgstr ""
|
1124 |
|
1125 |
+
#: src/Tribe/Languages/Locations.php:245
|
1126 |
+
msgid "São Tomé and Príncipe"
|
1127 |
msgstr ""
|
1128 |
|
1129 |
+
#: src/Tribe/Languages/Locations.php:246
|
1130 |
+
msgid "Saudi Arabia"
|
1131 |
msgstr ""
|
1132 |
|
1133 |
+
#: src/Tribe/Languages/Locations.php:247
|
1134 |
+
msgid "Senegal"
|
1135 |
msgstr ""
|
1136 |
|
1137 |
+
#: src/Tribe/Languages/Locations.php:248
|
1138 |
+
msgid "Serbia"
|
1139 |
msgstr ""
|
1140 |
|
1141 |
+
#: src/Tribe/Languages/Locations.php:249
|
1142 |
+
msgid "Seychelles"
|
1143 |
msgstr ""
|
1144 |
|
1145 |
+
#: src/Tribe/Languages/Locations.php:250
|
1146 |
+
msgid "Sierra Leone"
|
1147 |
msgstr ""
|
1148 |
|
1149 |
+
#: src/Tribe/Languages/Locations.php:251
|
1150 |
+
msgid "Singapore"
|
1151 |
msgstr ""
|
1152 |
|
1153 |
+
#: src/Tribe/Languages/Locations.php:252
|
1154 |
+
msgid "Sint Maarten"
|
1155 |
msgstr ""
|
1156 |
|
1157 |
+
#: src/Tribe/Languages/Locations.php:253
|
1158 |
+
msgid "Slovakia (Slovak Republic)"
|
1159 |
msgstr ""
|
1160 |
|
1161 |
+
#: src/Tribe/Languages/Locations.php:254
|
1162 |
+
msgid "Slovenia"
|
1163 |
msgstr ""
|
1164 |
|
1165 |
+
#: src/Tribe/Languages/Locations.php:255
|
1166 |
+
msgid "Solomon Islands"
|
1167 |
msgstr ""
|
1168 |
|
1169 |
+
#: src/Tribe/Languages/Locations.php:256
|
1170 |
+
msgid "Somalia"
|
1171 |
msgstr ""
|
1172 |
|
1173 |
+
#: src/Tribe/Languages/Locations.php:257
|
1174 |
+
msgid "South Africa"
|
1175 |
msgstr ""
|
1176 |
|
1177 |
+
#: src/Tribe/Languages/Locations.php:258
|
1178 |
+
msgid "South Georgia, South Sandwich Islands"
|
1179 |
msgstr ""
|
1180 |
|
1181 |
+
#: src/Tribe/Languages/Locations.php:259
|
1182 |
+
msgid "Spain"
|
1183 |
msgstr ""
|
1184 |
|
1185 |
+
#: src/Tribe/Languages/Locations.php:260
|
1186 |
+
msgid "Sri Lanka"
|
1187 |
msgstr ""
|
1188 |
|
1189 |
+
#: src/Tribe/Languages/Locations.php:261
|
1190 |
+
msgid "Sudan"
|
1191 |
msgstr ""
|
1192 |
|
1193 |
+
#: src/Tribe/Languages/Locations.php:262
|
1194 |
+
msgid "Suriname"
|
1195 |
msgstr ""
|
1196 |
|
1197 |
+
#: src/Tribe/Languages/Locations.php:263
|
1198 |
+
msgid "Svalbard and Jan Mayen Islands"
|
1199 |
msgstr ""
|
1200 |
|
1201 |
+
#: src/Tribe/Languages/Locations.php:264
|
1202 |
+
msgid "Swaziland"
|
1203 |
msgstr ""
|
1204 |
|
1205 |
+
#: src/Tribe/Languages/Locations.php:265
|
1206 |
+
msgid "Sweden"
|
1207 |
msgstr ""
|
1208 |
|
1209 |
+
#: src/Tribe/Languages/Locations.php:266
|
1210 |
+
msgid "Switzerland"
|
1211 |
msgstr ""
|
1212 |
|
1213 |
+
#: src/Tribe/Languages/Locations.php:267
|
1214 |
+
msgid "Syrian Arab Republic"
|
1215 |
+
msgstr ""
|
1216 |
+
|
1217 |
+
#: src/Tribe/Languages/Locations.php:268
|
1218 |
+
msgid "Taiwan"
|
1219 |
+
msgstr ""
|
1220 |
+
|
1221 |
+
#: src/Tribe/Languages/Locations.php:269
|
1222 |
+
msgid "Tajikistan"
|
1223 |
+
msgstr ""
|
1224 |
+
|
1225 |
+
#: src/Tribe/Languages/Locations.php:270
|
1226 |
+
msgid "Tanzania, United Republic of"
|
1227 |
+
msgstr ""
|
1228 |
+
|
1229 |
+
#: src/Tribe/Languages/Locations.php:271
|
1230 |
+
msgid "Thailand"
|
1231 |
+
msgstr ""
|
1232 |
+
|
1233 |
+
#: src/Tribe/Languages/Locations.php:272
|
1234 |
+
msgid "Togo"
|
1235 |
+
msgstr ""
|
1236 |
+
|
1237 |
+
#: src/Tribe/Languages/Locations.php:273
|
1238 |
+
msgid "Tokelau"
|
1239 |
+
msgstr ""
|
1240 |
+
|
1241 |
+
#: src/Tribe/Languages/Locations.php:274
|
1242 |
+
msgid "Tonga"
|
1243 |
+
msgstr ""
|
1244 |
+
|
1245 |
+
#: src/Tribe/Languages/Locations.php:275
|
1246 |
+
msgid "Trinidad and Tobago"
|
1247 |
+
msgstr ""
|
1248 |
+
|
1249 |
+
#: src/Tribe/Languages/Locations.php:276
|
1250 |
+
msgid "Tunisia"
|
1251 |
+
msgstr ""
|
1252 |
+
|
1253 |
+
#: src/Tribe/Languages/Locations.php:277
|
1254 |
+
msgid "Turkey"
|
1255 |
+
msgstr ""
|
1256 |
+
|
1257 |
+
#: src/Tribe/Languages/Locations.php:278
|
1258 |
+
msgid "Turkmenistan"
|
1259 |
msgstr ""
|
1260 |
|
1261 |
+
#: src/Tribe/Languages/Locations.php:279
|
1262 |
+
msgid "Turks and Caicos Islands"
|
1263 |
msgstr ""
|
1264 |
|
1265 |
+
#: src/Tribe/Languages/Locations.php:280
|
1266 |
+
msgid "Tuvalu"
|
1267 |
msgstr ""
|
1268 |
|
1269 |
+
#: src/Tribe/Languages/Locations.php:281
|
1270 |
+
msgid "Uganda"
|
1271 |
msgstr ""
|
1272 |
|
1273 |
+
#: src/Tribe/Languages/Locations.php:282
|
1274 |
+
msgid "Ukraine"
|
1275 |
msgstr ""
|
1276 |
|
1277 |
+
#: src/Tribe/Languages/Locations.php:283
|
1278 |
+
msgid "United Arab Emirates"
|
1279 |
msgstr ""
|
1280 |
|
1281 |
+
#: src/Tribe/Languages/Locations.php:284
|
1282 |
+
msgid "United Kingdom"
|
1283 |
msgstr ""
|
1284 |
|
1285 |
+
#: src/Tribe/Languages/Locations.php:285
|
1286 |
+
msgid "United States Minor Outlying Islands"
|
1287 |
msgstr ""
|
1288 |
|
1289 |
+
#: src/Tribe/Languages/Locations.php:286
|
1290 |
+
msgid "Uruguay"
|
1291 |
msgstr ""
|
1292 |
|
1293 |
+
#: src/Tribe/Languages/Locations.php:287
|
1294 |
+
msgid "Uzbekistan"
|
1295 |
msgstr ""
|
1296 |
|
1297 |
+
#: src/Tribe/Languages/Locations.php:288
|
1298 |
+
msgid "Vanuatu"
|
1299 |
msgstr ""
|
1300 |
|
1301 |
+
#: src/Tribe/Languages/Locations.php:289
|
1302 |
+
msgid "Venezuela"
|
1303 |
msgstr ""
|
1304 |
|
1305 |
+
#: src/Tribe/Languages/Locations.php:290
|
1306 |
+
msgid "Viet Nam"
|
1307 |
msgstr ""
|
1308 |
|
1309 |
+
#: src/Tribe/Languages/Locations.php:291
|
1310 |
+
msgid "Virgin Islands (British)"
|
1311 |
msgstr ""
|
1312 |
|
1313 |
+
#: src/Tribe/Languages/Locations.php:292
|
1314 |
+
msgid "Virgin Islands (U.S.)"
|
1315 |
msgstr ""
|
1316 |
|
1317 |
+
#: src/Tribe/Languages/Locations.php:293
|
1318 |
+
msgid "Wallis and Futuna Islands"
|
1319 |
msgstr ""
|
1320 |
|
1321 |
+
#: src/Tribe/Languages/Locations.php:294
|
1322 |
+
msgid "Western Sahara"
|
1323 |
msgstr ""
|
1324 |
|
1325 |
+
#: src/Tribe/Languages/Locations.php:295
|
1326 |
+
msgid "Yemen"
|
1327 |
msgstr ""
|
1328 |
|
1329 |
+
#: src/Tribe/Languages/Locations.php:296
|
1330 |
+
msgid "Zambia"
|
1331 |
msgstr ""
|
1332 |
|
1333 |
+
#: src/Tribe/Languages/Locations.php:297
|
1334 |
+
msgid "Zimbabwe"
|
1335 |
msgstr ""
|
1336 |
|
1337 |
+
#: src/Tribe/Languages/Locations.php:324
|
1338 |
+
msgid "Alabama"
|
1339 |
msgstr ""
|
1340 |
|
1341 |
+
#: src/Tribe/Languages/Locations.php:325
|
1342 |
+
msgid "Alaska"
|
1343 |
msgstr ""
|
1344 |
|
1345 |
+
#: src/Tribe/Languages/Locations.php:326
|
1346 |
+
msgid "Arizona"
|
1347 |
msgstr ""
|
1348 |
|
1349 |
+
#: src/Tribe/Languages/Locations.php:327
|
1350 |
+
msgid "Arkansas"
|
1351 |
msgstr ""
|
1352 |
|
1353 |
+
#: src/Tribe/Languages/Locations.php:328
|
1354 |
+
msgid "California"
|
1355 |
msgstr ""
|
1356 |
|
1357 |
+
#: src/Tribe/Languages/Locations.php:329
|
1358 |
+
msgid "Colorado"
|
1359 |
msgstr ""
|
1360 |
|
1361 |
+
#: src/Tribe/Languages/Locations.php:330
|
1362 |
+
msgid "Connecticut"
|
1363 |
msgstr ""
|
1364 |
|
1365 |
+
#: src/Tribe/Languages/Locations.php:331
|
1366 |
+
msgid "Delaware"
|
1367 |
msgstr ""
|
1368 |
|
1369 |
+
#: src/Tribe/Languages/Locations.php:332
|
1370 |
+
msgid "District of Columbia"
|
1371 |
msgstr ""
|
1372 |
|
1373 |
+
#: src/Tribe/Languages/Locations.php:333
|
1374 |
+
msgid "Florida"
|
1375 |
msgstr ""
|
1376 |
|
1377 |
+
#: src/Tribe/Languages/Locations.php:335
|
1378 |
+
msgid "Hawaii"
|
1379 |
msgstr ""
|
1380 |
|
1381 |
+
#: src/Tribe/Languages/Locations.php:336
|
1382 |
+
msgid "Idaho"
|
1383 |
msgstr ""
|
1384 |
|
1385 |
+
#: src/Tribe/Languages/Locations.php:337
|
1386 |
+
msgid "Illinois"
|
1387 |
msgstr ""
|
1388 |
|
1389 |
+
#: src/Tribe/Languages/Locations.php:338
|
1390 |
+
msgid "Indiana"
|
1391 |
msgstr ""
|
1392 |
|
1393 |
+
#: src/Tribe/Languages/Locations.php:339
|
1394 |
+
msgid "Iowa"
|
1395 |
msgstr ""
|
1396 |
|
1397 |
+
#: src/Tribe/Languages/Locations.php:340
|
1398 |
+
msgid "Kansas"
|
1399 |
msgstr ""
|
1400 |
|
1401 |
+
#: src/Tribe/Languages/Locations.php:341
|
1402 |
+
msgid "Kentucky"
|
1403 |
msgstr ""
|
1404 |
|
1405 |
+
#: src/Tribe/Languages/Locations.php:342
|
1406 |
+
msgid "Louisiana"
|
1407 |
msgstr ""
|
1408 |
|
1409 |
+
#: src/Tribe/Languages/Locations.php:343
|
1410 |
+
msgid "Maine"
|
1411 |
msgstr ""
|
1412 |
|
1413 |
+
#: src/Tribe/Languages/Locations.php:344
|
1414 |
+
msgid "Maryland"
|
1415 |
msgstr ""
|
1416 |
|
1417 |
+
#: src/Tribe/Languages/Locations.php:345
|
1418 |
+
msgid "Massachusetts"
|
1419 |
msgstr ""
|
1420 |
|
1421 |
+
#: src/Tribe/Languages/Locations.php:346
|
1422 |
+
msgid "Michigan"
|
1423 |
msgstr ""
|
1424 |
|
1425 |
+
#: src/Tribe/Languages/Locations.php:347
|
1426 |
+
msgid "Minnesota"
|
1427 |
msgstr ""
|
1428 |
|
1429 |
+
#: src/Tribe/Languages/Locations.php:348
|
1430 |
+
msgid "Mississippi"
|
1431 |
msgstr ""
|
1432 |
|
1433 |
+
#: src/Tribe/Languages/Locations.php:349
|
1434 |
+
msgid "Missouri"
|
1435 |
msgstr ""
|
1436 |
|
1437 |
+
#: src/Tribe/Languages/Locations.php:350
|
1438 |
+
msgid "Montana"
|
1439 |
msgstr ""
|
1440 |
|
1441 |
+
#: src/Tribe/Languages/Locations.php:351
|
1442 |
+
msgid "Nebraska"
|
1443 |
msgstr ""
|
1444 |
|
1445 |
+
#: src/Tribe/Languages/Locations.php:352
|
1446 |
+
msgid "Nevada"
|
1447 |
msgstr ""
|
1448 |
|
1449 |
+
#: src/Tribe/Languages/Locations.php:353
|
1450 |
+
msgid "New Hampshire"
|
1451 |
msgstr ""
|
1452 |
|
1453 |
+
#: src/Tribe/Languages/Locations.php:354
|
1454 |
+
msgid "New Jersey"
|
1455 |
msgstr ""
|
1456 |
|
1457 |
+
#: src/Tribe/Languages/Locations.php:355
|
1458 |
+
msgid "New Mexico"
|
1459 |
msgstr ""
|
1460 |
|
1461 |
+
#: src/Tribe/Languages/Locations.php:356
|
1462 |
+
msgid "New York"
|
1463 |
msgstr ""
|
1464 |
|
1465 |
+
#: src/Tribe/Languages/Locations.php:357
|
1466 |
+
msgid "North Carolina"
|
1467 |
msgstr ""
|
1468 |
|
1469 |
+
#: src/Tribe/Languages/Locations.php:358
|
1470 |
+
msgid "North Dakota"
|
1471 |
msgstr ""
|
1472 |
|
1473 |
+
#: src/Tribe/Languages/Locations.php:359
|
1474 |
+
msgid "Ohio"
|
1475 |
msgstr ""
|
1476 |
|
1477 |
+
#: src/Tribe/Languages/Locations.php:360
|
1478 |
+
msgid "Oklahoma"
|
1479 |
msgstr ""
|
1480 |
|
1481 |
+
#: src/Tribe/Languages/Locations.php:361
|
1482 |
+
msgid "Oregon"
|
1483 |
msgstr ""
|
1484 |
|
1485 |
+
#: src/Tribe/Languages/Locations.php:362
|
1486 |
+
msgid "Pennsylvania"
|
1487 |
msgstr ""
|
1488 |
|
1489 |
+
#: src/Tribe/Languages/Locations.php:363
|
1490 |
+
msgid "Rhode Island"
|
1491 |
msgstr ""
|
1492 |
|
1493 |
+
#: src/Tribe/Languages/Locations.php:364
|
1494 |
+
msgid "South Carolina"
|
1495 |
msgstr ""
|
1496 |
|
1497 |
+
#: src/Tribe/Languages/Locations.php:365
|
1498 |
+
msgid "South Dakota"
|
1499 |
msgstr ""
|
1500 |
|
1501 |
+
#: src/Tribe/Languages/Locations.php:366
|
1502 |
+
msgid "Tennessee"
|
1503 |
msgstr ""
|
1504 |
|
1505 |
+
#: src/Tribe/Languages/Locations.php:367
|
1506 |
+
msgid "Texas"
|
1507 |
msgstr ""
|
1508 |
|
1509 |
+
#: src/Tribe/Languages/Locations.php:368
|
1510 |
+
msgid "Utah"
|
1511 |
msgstr ""
|
1512 |
|
1513 |
+
#: src/Tribe/Languages/Locations.php:369
|
1514 |
+
msgid "Vermont"
|
1515 |
msgstr ""
|
1516 |
|
1517 |
+
#: src/Tribe/Languages/Locations.php:370
|
1518 |
+
msgid "Virginia"
|
1519 |
msgstr ""
|
1520 |
|
1521 |
+
#: src/Tribe/Languages/Locations.php:371
|
1522 |
+
msgid "Washington"
|
1523 |
msgstr ""
|
1524 |
|
1525 |
+
#: src/Tribe/Languages/Locations.php:372
|
1526 |
+
msgid "West Virginia"
|
1527 |
msgstr ""
|
1528 |
|
1529 |
+
#: src/Tribe/Languages/Locations.php:373
|
1530 |
+
msgid "Wisconsin"
|
1531 |
msgstr ""
|
1532 |
|
1533 |
+
#: src/Tribe/Languages/Locations.php:374
|
1534 |
+
msgid "Wyoming"
|
1535 |
msgstr ""
|
1536 |
|
1537 |
+
#: src/Tribe/Log/Admin.php:133
|
1538 |
+
msgctxt "log selector"
|
1539 |
+
msgid "None currently available"
|
1540 |
msgstr ""
|
1541 |
|
1542 |
+
#: src/Tribe/Log/Admin.php:148
|
1543 |
+
msgctxt "log engines"
|
1544 |
+
msgid "None currently available"
|
1545 |
msgstr ""
|
1546 |
|
1547 |
+
#: src/Tribe/Log/File_Logger.php:128
|
1548 |
+
msgid "Default (uses temporary files)"
|
1549 |
msgstr ""
|
1550 |
|
1551 |
+
#: src/Tribe/Log/Null_Logger.php:26
|
1552 |
+
msgid "Null logger (will log nothing)"
|
1553 |
msgstr ""
|
1554 |
|
1555 |
+
#: src/Tribe/Log.php:274
|
1556 |
+
msgid "Cannot set %s as the current logging engine"
|
1557 |
msgstr ""
|
1558 |
|
1559 |
+
#: src/Tribe/Log.php:373
|
1560 |
+
msgid "Disabled"
|
1561 |
msgstr ""
|
1562 |
|
1563 |
+
#: src/Tribe/Log.php:374
|
1564 |
+
msgid "Only errors"
|
1565 |
msgstr ""
|
1566 |
|
1567 |
+
#: src/Tribe/Log.php:375
|
1568 |
+
msgid "Warnings and errors"
|
1569 |
msgstr ""
|
1570 |
|
1571 |
+
#: src/Tribe/Log.php:376
|
1572 |
+
msgid "Full debug (all events)"
|
1573 |
msgstr ""
|
1574 |
|
1575 |
+
#: src/Tribe/Main.php:224 src/admin-views/tribe-options-help.php:50
|
1576 |
+
msgid "Copy to clipboard"
|
1577 |
msgstr ""
|
1578 |
|
1579 |
+
#: src/Tribe/Main.php:225
|
1580 |
+
msgid "System info copied"
|
1581 |
msgstr ""
|
1582 |
|
1583 |
+
#: src/Tribe/Main.php:226
|
1584 |
+
msgid "Press \"Cmd + C\" to copy"
|
1585 |
msgstr ""
|
1586 |
|
1587 |
+
#: src/Tribe/Main.php:245
|
1588 |
+
msgid ": activate to sort column ascending"
|
1589 |
msgstr ""
|
1590 |
|
1591 |
+
#: src/Tribe/Main.php:246
|
1592 |
+
msgid ": activate to sort column descending"
|
1593 |
msgstr ""
|
1594 |
|
1595 |
+
#: src/Tribe/Main.php:248
|
1596 |
+
msgid "Show _MENU_ entries"
|
1597 |
msgstr ""
|
1598 |
|
1599 |
+
#: src/Tribe/Main.php:249
|
1600 |
+
msgid "No data available in table"
|
1601 |
msgstr ""
|
1602 |
|
1603 |
+
#: src/Tribe/Main.php:250
|
1604 |
+
msgid "Showing _START_ to _END_ of _TOTAL_ entries"
|
1605 |
msgstr ""
|
1606 |
|
1607 |
+
#: src/Tribe/Main.php:251
|
1608 |
+
msgid "Showing 0 to 0 of 0 entries"
|
1609 |
msgstr ""
|
1610 |
|
1611 |
+
#: src/Tribe/Main.php:252
|
1612 |
+
msgid "(filtered from _MAX_ total entries)"
|
1613 |
msgstr ""
|
1614 |
|
1615 |
+
#: src/Tribe/Main.php:253
|
1616 |
+
msgid "No matching records found"
|
1617 |
msgstr ""
|
1618 |
|
1619 |
+
#: src/Tribe/Main.php:254
|
1620 |
+
msgid "Search:"
|
1621 |
msgstr ""
|
1622 |
|
1623 |
+
#: src/Tribe/Main.php:255
|
1624 |
+
msgid "All items on this page were selected. "
|
1625 |
msgstr ""
|
1626 |
|
1627 |
+
#: src/Tribe/Main.php:256
|
1628 |
+
msgid "Select all pages"
|
1629 |
msgstr ""
|
1630 |
|
1631 |
+
#: src/Tribe/Main.php:257
|
1632 |
+
msgid "Clear Selection."
|
1633 |
msgstr ""
|
1634 |
|
1635 |
+
#: src/Tribe/Main.php:259
|
1636 |
+
msgid "All"
|
1637 |
msgstr ""
|
1638 |
|
1639 |
+
#: src/Tribe/Main.php:260 src/Tribe/Main.php:276
|
1640 |
+
msgid "Next"
|
1641 |
msgstr ""
|
1642 |
|
1643 |
+
#: src/Tribe/Main.php:261
|
1644 |
+
msgid "Previous"
|
1645 |
msgstr ""
|
1646 |
|
1647 |
+
#: src/Tribe/Main.php:266
|
1648 |
+
msgid ": Selected %d rows"
|
1649 |
msgstr ""
|
1650 |
|
1651 |
+
#: src/Tribe/Main.php:267
|
1652 |
+
msgid ": Selected 1 row"
|
1653 |
msgstr ""
|
1654 |
|
1655 |
+
#: src/Tribe/Main.php:277
|
1656 |
+
msgid "Prev"
|
1657 |
msgstr ""
|
1658 |
|
1659 |
+
#: src/Tribe/Main.php:278
|
1660 |
+
msgid "Today"
|
1661 |
msgstr ""
|
1662 |
|
1663 |
+
#: src/Tribe/Main.php:279
|
1664 |
+
msgid "Done"
|
1665 |
msgstr ""
|
1666 |
|
1667 |
+
#: src/Tribe/PUE/Checker.php:494
|
1668 |
+
msgid "A valid license key is required for support and updates"
|
1669 |
msgstr ""
|
1670 |
|
1671 |
+
#: src/Tribe/PUE/Checker.php:497
|
1672 |
+
msgid ""
|
1673 |
+
"%1$sBuy a license%2$s for the Event Aggregator service to access additional "
|
1674 |
+
"import features."
|
1675 |
msgstr ""
|
1676 |
|
1677 |
+
#: src/Tribe/PUE/Checker.php:509 src/Tribe/PUE/Checker.php:520
|
1678 |
+
msgid "License Key"
|
1679 |
msgstr ""
|
1680 |
|
1681 |
+
#: src/Tribe/PUE/Checker.php:529 src/Tribe/PUE/Checker.php:563
|
1682 |
+
msgid "License Key Status:"
|
1683 |
msgstr ""
|
1684 |
|
1685 |
+
#: src/Tribe/PUE/Checker.php:538
|
1686 |
+
msgid "Override network license key"
|
1687 |
msgstr ""
|
1688 |
|
1689 |
+
#: src/Tribe/PUE/Checker.php:539
|
1690 |
+
msgid ""
|
1691 |
+
"Check this box if you wish to override the network license key with your own"
|
1692 |
msgstr ""
|
1693 |
|
1694 |
+
#: src/Tribe/PUE/Checker.php:550
|
1695 |
+
msgid "Site License Key"
|
1696 |
msgstr ""
|
1697 |
|
1698 |
+
#: src/Tribe/PUE/Checker.php:650
|
1699 |
+
msgid "License key(s) updated."
|
1700 |
msgstr ""
|
1701 |
|
1702 |
+
#: src/Tribe/PUE/Checker.php:888
|
1703 |
+
msgid ""
|
1704 |
+
"Hmmm... something's wrong with this validator. Please contact %ssupport%s."
|
1705 |
msgstr ""
|
1706 |
|
1707 |
+
#: src/Tribe/PUE/Checker.php:901
|
1708 |
+
msgid "unknown date"
|
1709 |
msgstr ""
|
1710 |
|
1711 |
+
#: src/Tribe/PUE/Checker.php:907
|
1712 |
+
msgid "Sorry, key validation server is not available."
|
1713 |
msgstr ""
|
1714 |
|
1715 |
+
#: src/Tribe/PUE/Checker.php:927
|
1716 |
+
msgid "Valid Key! Expires on %s"
|
1717 |
msgstr ""
|
1718 |
|
1719 |
+
#: src/Tribe/PUE/Checker.php:932
|
1720 |
+
msgid "Thanks for setting up a valid key. It will expire on %s"
|
1721 |
msgstr ""
|
1722 |
|
1723 |
+
#: src/Tribe/PUE/Checker.php:959 src/Tribe/PUE/Notices.php:283
|
1724 |
+
msgid "Renew Your License Now"
|
1725 |
msgstr ""
|
1726 |
|
1727 |
+
#: src/Tribe/PUE/Checker.php:961 src/Tribe/PUE/Notices.php:285
|
1728 |
+
msgid " (opens in a new window)"
|
1729 |
msgstr ""
|
1730 |
|
1731 |
+
#: src/Tribe/PUE/Checker.php:976
|
1732 |
+
msgid "Please refresh the page and try your request again."
|
1733 |
msgstr ""
|
1734 |
|
1735 |
+
#: src/Tribe/PUE/Checker.php:997
|
1736 |
+
msgid ""
|
1737 |
+
"There is an update for %s. You'll need to %scheck your license%s to have "
|
1738 |
+
"access to updates, downloads, and support."
|
1739 |
msgstr ""
|
1740 |
|
1741 |
+
#: src/Tribe/PUE/Checker.php:1054
|
1742 |
+
msgid ""
|
1743 |
+
"There is an update for %s. %sRenew your license%s to get access to bug "
|
1744 |
+
"fixes, security updates, and new features."
|
1745 |
msgstr ""
|
1746 |
|
1747 |
+
#: src/Tribe/PUE/Checker.php:1084
|
1748 |
+
msgid "Update now to version %s."
|
1749 |
msgstr ""
|
1750 |
|
1751 |
+
#: src/Tribe/PUE/Checker.php:1095
|
1752 |
+
msgid "There is a new version of %1$s available. %2$s"
|
1753 |
msgstr ""
|
1754 |
|
1755 |
+
#: src/Tribe/PUE/Checker.php:1668
|
1756 |
+
msgid "A valid license has been entered by your network administrator."
|
1757 |
msgstr ""
|
1758 |
|
1759 |
+
#: src/Tribe/PUE/Checker.php:1669
|
1760 |
+
msgid "No license entered. Consult your network administrator."
|
1761 |
msgstr ""
|
1762 |
|
1763 |
+
#: src/Tribe/PUE/Checker.php:1670
|
1764 |
+
msgid "Expired license. Consult your network administrator."
|
1765 |
msgstr ""
|
1766 |
|
1767 |
+
#: src/Tribe/PUE/Notices.php:225
|
1768 |
+
msgid ""
|
1769 |
+
"It looks like you're using %1$s, but the license key is invalid. Please "
|
1770 |
+
"download the latest version %2$sfrom your account%3$s."
|
1771 |
+
msgid_plural ""
|
1772 |
+
"It looks like you're using %1$s, but the license keys are invalid. Please "
|
1773 |
+
"download the latest versions %2$sfrom your account%3$s."
|
1774 |
+
msgstr[0] ""
|
1775 |
+
msgstr[1] ""
|
1776 |
|
1777 |
+
#: src/Tribe/PUE/Notices.php:270
|
1778 |
+
msgid ""
|
1779 |
+
"There is an update available for %1$s but your license has expired. "
|
1780 |
+
"%2$sVisit the Events Calendar website to renew your license.%3$s"
|
1781 |
+
msgid_plural ""
|
1782 |
+
"Updates are available for %1$s but your license keys have expired. %2$sVisit "
|
1783 |
+
"the Events Calendar website to renew your licenses.%3$s"
|
1784 |
+
msgstr[0] ""
|
1785 |
+
msgstr[1] ""
|
1786 |
+
|
1787 |
+
#: src/Tribe/PUE/Notices.php:302
|
1788 |
+
msgid ""
|
1789 |
+
"You have a license key for %1$s but the key is out of installs. %2$sVisit "
|
1790 |
+
"the Events Calendar website%3$s to manage your installs, upgrade your "
|
1791 |
+
"license, or purchase a new one."
|
1792 |
+
msgid_plural ""
|
1793 |
+
"You have license keys for %1$s but your keys are out of installs. %2$sVisit "
|
1794 |
+
"the Events Calendar website%3$s to manage your installs, upgrade your "
|
1795 |
+
"licenses, or purchase new ones."
|
1796 |
+
msgstr[0] ""
|
1797 |
+
msgstr[1] ""
|
1798 |
+
|
1799 |
+
#: src/Tribe/PUE/Notices.php:340
|
1800 |
+
msgid ""
|
1801 |
+
"You can always check the status of your licenses by logging in to %1$syour "
|
1802 |
+
"account on theeventscalendar.com%2$s."
|
1803 |
msgstr ""
|
1804 |
|
1805 |
+
#: src/Tribe/PUE/Notices.php:383
|
1806 |
+
msgctxt "formatted plugin list"
|
1807 |
+
msgid "%1$s and %2$s"
|
1808 |
msgstr ""
|
1809 |
|
1810 |
+
#: src/Tribe/Plugins_API.php:28
|
1811 |
+
msgid ""
|
1812 |
+
"Create an events calendar and manage it with ease. The Events Calendar "
|
1813 |
+
"plugin provides professional-level quality and features backed by a team you "
|
1814 |
+
"can trust."
|
1815 |
msgstr ""
|
1816 |
|
1817 |
+
#: src/Tribe/Plugins_API.php:37
|
1818 |
+
msgid ""
|
1819 |
+
"Import events from across the web! Event Aggregator makes it easy to run "
|
1820 |
+
"scheduled or manual imports from Facebook, Meetup, Google Calendar, and "
|
1821 |
+
"iCalendar, along with uploads from CSV and ICS files. You can also import "
|
1822 |
+
"directly from other sites running The Events Calendar thanks to our built-in "
|
1823 |
+
"REST API support."
|
1824 |
msgstr ""
|
1825 |
|
1826 |
+
#: src/Tribe/Plugins_API.php:48
|
1827 |
+
msgid ""
|
1828 |
+
"The Events Calendar PRO is a paid Add-On to our open source WordPress plugin "
|
1829 |
+
"%1$sThe Events Calendar%2$s. PRO offers a whole host of calendar features "
|
1830 |
+
"including recurring events, custom event attributes, saved venues and "
|
1831 |
+
"organizers, venue pages, advanced event admin and lots more."
|
1832 |
msgstr ""
|
1833 |
|
1834 |
+
#: src/Tribe/Plugins_API.php:60
|
1835 |
+
msgid ""
|
1836 |
+
"Event Tickets provides a simple way for visitors to RSVP to your events. As "
|
1837 |
+
"a standalone plugin, it enables you to add RSVP functionality to posts or "
|
1838 |
+
"pages. When paired with The Events Calendar, you can add that same RSVP "
|
1839 |
+
"functionality directly to your event listings."
|
1840 |
msgstr ""
|
1841 |
|
1842 |
+
#: src/Tribe/Plugins_API.php:71
|
1843 |
+
msgid ""
|
1844 |
+
"Event Tickets Plus allows you to sell tickets to your events using "
|
1845 |
+
"WooCommerce, Easy Digital Downloads, or our built in Tribe Commerce tool. "
|
1846 |
+
"Add tickets to your posts and pages, or add %1$sThe Events Calendar%2$s and "
|
1847 |
+
"sell tickets from your event listings. Create custom registration forms, "
|
1848 |
+
"manage attendees, use custom capacity options, and more. Tickets have QR "
|
1849 |
+
"codes for easy check in at the door."
|
1850 |
msgstr ""
|
1851 |
|
1852 |
+
#: src/Tribe/Plugins_API.php:84
|
1853 |
+
msgid ""
|
1854 |
+
"It is awesome that your calendar is <em>THE PLACE</em> to get hooked up with "
|
1855 |
+
"prime choice ways to spend time. You have more events than Jabba the Hutt "
|
1856 |
+
"has rolls. Too bad visitors are hiring a personal assistant to go through "
|
1857 |
+
"all the choices. Ever wish you could just filter the calendar to only show "
|
1858 |
+
"events in walking distance, on a weekend, that are free? BOOM. Now you can. "
|
1859 |
+
"Introducing… the Filter Bar."
|
1860 |
msgstr ""
|
1861 |
|
1862 |
+
#: src/Tribe/Plugins_API.php:94
|
1863 |
+
msgid ""
|
1864 |
+
"Accept user-submitted events on your site! With Community Events, you can "
|
1865 |
+
"accept public submissions or require account sign-on. Settings give you the "
|
1866 |
+
"options to save as a draft or publish automatically, enable categories and "
|
1867 |
+
"tags, and choose whether users can edit/manage their own events or simply "
|
1868 |
+
"submit. Best of all - setup is easy! Just activate, configure the options, "
|
1869 |
+
"and off you go."
|
1870 |
msgstr ""
|
1871 |
|
1872 |
+
#: src/Tribe/Plugins_API.php:104
|
1873 |
+
msgid ""
|
1874 |
+
"Enable Community Events organizers to offer tickets to their events. You can "
|
1875 |
+
"set flexible payment and fee options. They can even check-in attendees to "
|
1876 |
+
"their events! All of this managed from the front-end of your site without "
|
1877 |
+
"ever needing to grant access to your admin"
|
1878 |
msgstr ""
|
1879 |
|
1880 |
+
#: src/Tribe/Plugins_API.php:105
|
1881 |
+
msgctxt "Names of required plugins for Community Tickets"
|
1882 |
+
msgid "Event Tickets Plus and Community Events"
|
1883 |
msgstr ""
|
1884 |
|
1885 |
+
#: src/Tribe/Plugins_API.php:116
|
1886 |
+
msgid ""
|
1887 |
+
"The Eventbrite Tickets add-on allows you to create & sell tickets through "
|
1888 |
+
"The Events Calendar using the power of %1$sEventbrite%2$s. Whether you’re "
|
1889 |
+
"creating your ticket on the WordPress dashboard or importing the details of "
|
1890 |
+
"an already-existing event from %1$sEventbrite.com%2$s, this add-on brings "
|
1891 |
+
"the power of the Eventbrite API to your calendar."
|
1892 |
msgstr ""
|
1893 |
|
1894 |
+
#: src/Tribe/Plugins_API.php:125
|
1895 |
+
msgid "Image Widget Plus"
|
1896 |
msgstr ""
|
1897 |
|
1898 |
+
#: src/Tribe/Plugins_API.php:129
|
1899 |
+
msgid ""
|
1900 |
+
"Take your image widgets to the next level with Image Widget Plus! We've "
|
1901 |
+
"taken the simple functionality of our basic Image Widget and amped it up "
|
1902 |
+
"with several popular feature requests - multiple image support, slideshow, "
|
1903 |
+
"lightbox, and random image - all backed by a full year of premium support."
|
1904 |
msgstr ""
|
1905 |
|
1906 |
+
#: src/Tribe/Settings.php:177 src/Tribe/Settings.php:241
|
1907 |
+
#: src/Tribe/Settings.php:242
|
1908 |
+
msgid "Events"
|
1909 |
msgstr ""
|
1910 |
|
1911 |
+
#: src/Tribe/Settings.php:253 src/Tribe/Settings.php:273
|
1912 |
+
msgid "Events Settings"
|
1913 |
msgstr ""
|
1914 |
|
1915 |
+
#: src/Tribe/Settings.php:254
|
1916 |
+
msgid "Settings"
|
1917 |
msgstr ""
|
1918 |
|
1919 |
+
#: src/Tribe/Settings.php:281 src/Tribe/Settings.php:282
|
1920 |
+
msgid "Events Help"
|
1921 |
msgstr ""
|
1922 |
|
1923 |
+
#: src/Tribe/Settings.php:349
|
1924 |
+
msgid "%s Settings"
|
1925 |
msgstr ""
|
1926 |
|
1927 |
+
#: src/Tribe/Settings.php:363
|
1928 |
+
msgid "You've requested a non-existent tab."
|
1929 |
msgstr ""
|
1930 |
|
1931 |
+
#: src/Tribe/Settings.php:371
|
1932 |
+
msgid "Save Changes"
|
1933 |
msgstr ""
|
1934 |
|
1935 |
+
#: src/Tribe/Settings.php:419
|
1936 |
+
msgid "You don't have permission to do that."
|
1937 |
msgstr ""
|
1938 |
|
1939 |
+
#: src/Tribe/Settings.php:425
|
1940 |
+
msgid "The request was sent insecurely."
|
1941 |
msgstr ""
|
1942 |
|
1943 |
+
#: src/Tribe/Settings.php:431
|
1944 |
+
msgid "The request wasn't sent from this tab."
|
1945 |
msgstr ""
|
1946 |
|
1947 |
+
#: src/Tribe/Settings.php:610
|
1948 |
+
msgid "Your form had the following errors:"
|
1949 |
msgstr ""
|
1950 |
|
1951 |
+
#: src/Tribe/Settings.php:620
|
1952 |
+
msgid "None of your settings were saved. Please try again."
|
1953 |
msgstr ""
|
1954 |
|
1955 |
+
#: src/Tribe/Settings.php:621
|
1956 |
+
msgid ""
|
1957 |
+
"The above setting was not saved. Other settings were successfully saved."
|
1958 |
+
msgid_plural ""
|
1959 |
+
"The above settings were not saved. Other settings were successfully saved."
|
1960 |
+
msgstr[0] ""
|
1961 |
+
msgstr[1] ""
|
1962 |
+
|
1963 |
+
#: src/Tribe/Settings.php:643
|
1964 |
+
msgid "Settings saved."
|
1965 |
msgstr ""
|
1966 |
|
1967 |
+
#: src/Tribe/Settings_Manager.php:54
|
1968 |
+
msgid "General"
|
1969 |
msgstr ""
|
1970 |
|
1971 |
+
#: src/Tribe/Settings_Manager.php:55
|
1972 |
+
msgid "Display"
|
1973 |
msgstr ""
|
1974 |
|
1975 |
+
#: src/Tribe/Settings_Manager.php:219
|
1976 |
+
msgid "Network"
|
1977 |
msgstr ""
|
1978 |
|
1979 |
+
#: src/Tribe/Settings_Manager.php:253
|
1980 |
+
#: src/admin-views/tribe-options-licenses.php:66
|
1981 |
+
msgid "Licenses"
|
1982 |
msgstr ""
|
1983 |
|
1984 |
+
#: src/Tribe/Settings_Manager.php:279
|
1985 |
+
msgid "Help"
|
1986 |
msgstr ""
|
1987 |
|
1988 |
+
#: src/Tribe/Settings_Tab.php:222
|
1989 |
+
msgid "There are no fields setup for this tab yet."
|
1990 |
msgstr ""
|
1991 |
|
1992 |
+
#: src/Tribe/Support/Template_Checker_Report.php:78
|
1993 |
+
msgid "No notable changes detected"
|
1994 |
msgstr ""
|
1995 |
|
1996 |
+
#: src/Tribe/Support/Template_Checker_Report.php:82
|
1997 |
+
msgid "Templates introduced or updated with this release (%s):"
|
1998 |
msgstr ""
|
1999 |
|
2000 |
+
#: src/Tribe/Support/Template_Checker_Report.php:92
|
2001 |
+
msgid "Existing theme overrides that may need revision:"
|
2002 |
msgstr ""
|
2003 |
|
2004 |
+
#: src/Tribe/Support/Template_Checker_Report.php:96
|
2005 |
+
msgid "version data missing from override"
|
2006 |
msgstr ""
|
2007 |
|
2008 |
+
#: src/Tribe/Support/Template_Checker_Report.php:97
|
2009 |
+
msgid "based on %s version"
|
2010 |
msgstr ""
|
2011 |
|
2012 |
+
#: src/Tribe/Support/Template_Checker_Report.php:113
|
2013 |
+
msgid "No notable template changes detected."
|
2014 |
msgstr ""
|
2015 |
|
2016 |
+
#: src/Tribe/Support/Template_Checker_Report.php:115
|
2017 |
+
msgid ""
|
2018 |
+
"Information about recent template changes and potentially impacted template "
|
2019 |
+
"overrides is provided below."
|
2020 |
msgstr ""
|
2021 |
|
2022 |
+
#: src/Tribe/Support.php:171
|
2023 |
+
msgid "English"
|
2024 |
msgstr ""
|
2025 |
|
2026 |
+
#: src/Tribe/Support.php:188 src/Tribe/Support.php:189
|
2027 |
+
msgid "Unknown or not set"
|
2028 |
msgstr ""
|
2029 |
|
2030 |
+
#: src/Tribe/Support.php:199
|
2031 |
+
msgid ""
|
2032 |
+
"Rewrite rules were purged on load of this help page. Chances are there is a "
|
2033 |
+
"rewrite rule flush occurring in a plugin or theme!"
|
2034 |
msgstr ""
|
2035 |
|
2036 |
+
#: src/Tribe/Support.php:305
|
2037 |
+
msgid ""
|
2038 |
+
"Yes, automatically share my system information with the Modern Tribe support "
|
2039 |
+
"team"
|
2040 |
msgstr ""
|
2041 |
|
2042 |
+
#: src/Tribe/Support.php:306
|
2043 |
+
msgid ""
|
2044 |
+
"Your system information will only be used by the Modern Tribe support team. "
|
2045 |
+
"All information is stored securely. We do not share this information with "
|
2046 |
+
"any third parties."
|
2047 |
msgstr ""
|
2048 |
|
2049 |
+
#: src/Tribe/Support.php:325 src/Tribe/Support.php:330
|
2050 |
+
msgid "Invalid Key"
|
2051 |
msgstr ""
|
2052 |
|
2053 |
+
#: src/Tribe/Support.php:358 src/Tribe/Support.php:384
|
2054 |
+
msgid "Permission Error"
|
2055 |
msgstr ""
|
2056 |
|
2057 |
+
#: src/Tribe/Support.php:372
|
2058 |
+
msgid "Unique System Info Key Generated"
|
2059 |
msgstr ""
|
2060 |
|
2061 |
+
#: src/Tribe/Validate.php:72 src/Tribe/Validate.php:84
|
2062 |
+
msgid "Invalid or incomplete field passed"
|
2063 |
msgstr ""
|
2064 |
|
2065 |
+
#: src/Tribe/Validate.php:73 src/Tribe/Validate.php:85
|
2066 |
+
#: src/Tribe/Validate.php:105
|
2067 |
+
msgid "Field ID:"
|
2068 |
msgstr ""
|
2069 |
|
2070 |
+
#: src/Tribe/Validate.php:104
|
2071 |
+
msgid "Non-existant field validation function passed"
|
2072 |
msgstr ""
|
2073 |
|
2074 |
+
#: src/Tribe/Validate.php:105
|
2075 |
+
msgctxt "non-existant function name passed for field validation"
|
2076 |
+
msgid "with function name:"
|
2077 |
msgstr ""
|
2078 |
|
2079 |
+
#: src/Tribe/Validate.php:120 src/Tribe/Validate.php:136
|
2080 |
+
msgid "%s must contain numbers and letters only"
|
2081 |
msgstr ""
|
2082 |
|
2083 |
+
#: src/Tribe/Validate.php:152
|
2084 |
+
msgid "%s must contain numbers, letters and dots only"
|
2085 |
msgstr ""
|
2086 |
|
2087 |
+
#: src/Tribe/Validate.php:168
|
2088 |
+
msgid "%s must contain numbers, letters, dashes and undescores only"
|
2089 |
msgstr ""
|
2090 |
|
2091 |
+
#: src/Tribe/Validate.php:184
|
2092 |
+
msgid "%s must not be empty"
|
2093 |
msgstr ""
|
2094 |
|
2095 |
+
#: src/Tribe/Validate.php:200 src/Tribe/Validate.php:228
|
2096 |
+
msgid "%s must be a positive number."
|
2097 |
msgstr ""
|
2098 |
|
2099 |
+
#: src/Tribe/Validate.php:214
|
2100 |
+
msgid "%s must be a positive number or percent."
|
2101 |
msgstr ""
|
2102 |
|
2103 |
+
#: src/Tribe/Validate.php:248
|
2104 |
+
msgid "%s must be a whole number."
|
2105 |
msgstr ""
|
2106 |
|
2107 |
+
#: src/Tribe/Validate.php:267
|
2108 |
+
msgid "%s must be a valid slug (numbers, letters, dashes, and underscores)."
|
2109 |
msgstr ""
|
2110 |
|
2111 |
+
#: src/Tribe/Validate.php:282
|
2112 |
+
msgid "%s must be a valid absolute URL."
|
2113 |
msgstr ""
|
2114 |
|
2115 |
+
#: src/Tribe/Validate.php:298 src/Tribe/Validate.php:310
|
2116 |
+
#: src/Tribe/Validate.php:323 src/Tribe/Validate.php:345
|
2117 |
+
msgid "%s must have a value that's part of its options."
|
2118 |
msgstr ""
|
2119 |
|
2120 |
+
#: src/Tribe/Validate.php:359
|
2121 |
+
msgid ""
|
2122 |
+
"Comparison validation failed because no comparison value was provided, for "
|
2123 |
+
"field %s"
|
2124 |
msgstr ""
|
2125 |
|
2126 |
+
#: src/Tribe/Validate.php:366
|
2127 |
+
msgid "%s cannot be the same as %s."
|
2128 |
msgstr ""
|
2129 |
|
2130 |
+
#: src/Tribe/Validate.php:368
|
2131 |
+
msgid "%s cannot be a duplicate"
|
2132 |
msgstr ""
|
2133 |
|
2134 |
+
#: src/Tribe/Validate.php:384
|
2135 |
+
msgid "%s must be a number or percentage."
|
2136 |
msgstr ""
|
2137 |
|
2138 |
+
#: src/Tribe/Validate.php:438
|
2139 |
+
msgid "%s must be a number between 0 and 21."
|
2140 |
msgstr ""
|
2141 |
|
2142 |
+
#: src/Tribe/Validate.php:454
|
2143 |
+
msgid ""
|
2144 |
+
"%s must consist of letters, numbers, dashes, apostrophes, and spaces only."
|
2145 |
msgstr ""
|
2146 |
|
2147 |
+
#: src/Tribe/Validate.php:470
|
2148 |
+
msgid "%s must consist of letters, spaces, apostrophes, and dashes."
|
|
|
2149 |
msgstr ""
|
2150 |
|
2151 |
+
#: src/Tribe/Validate.php:484
|
2152 |
+
msgid "%s must consist of 5 numbers."
|
|
|
2153 |
msgstr ""
|
2154 |
|
2155 |
+
#: src/Tribe/Validate.php:498
|
2156 |
+
msgid "%s must be a phone number."
|
2157 |
msgstr ""
|
2158 |
|
2159 |
+
#: src/Tribe/Validate.php:514
|
2160 |
+
msgid ""
|
2161 |
+
"Country List must be formatted as one country per line in the following "
|
2162 |
+
"format: <br>US, United States <br> UK, United Kingdom."
|
2163 |
msgstr ""
|
2164 |
|
2165 |
+
#: src/Tribe/Validate.php:545
|
2166 |
+
msgid "%s must be an email address."
|
2167 |
msgstr ""
|
2168 |
|
2169 |
+
#: src/Tribe/View_Helpers.php:50
|
2170 |
+
msgid "Select a Country:"
|
2171 |
msgstr ""
|
2172 |
|
2173 |
+
#: src/admin-views/app-shop.php:4
|
2174 |
+
msgid "Events Add-Ons"
|
2175 |
msgstr ""
|
2176 |
|
2177 |
+
#: src/admin-views/app-shop.php:5
|
2178 |
+
msgid "Browse All Add-Ons"
|
2179 |
msgstr ""
|
2180 |
|
2181 |
+
#: src/admin-views/app-shop.php:26
|
2182 |
+
msgid "Buy This Add-On"
|
2183 |
msgstr ""
|
2184 |
|
2185 |
+
#: src/admin-views/app-shop.php:29
|
2186 |
+
msgid "Installed Add-Ons"
|
2187 |
msgstr ""
|
2188 |
|
2189 |
+
#: src/admin-views/app-shop.php:31
|
2190 |
+
msgid "Installed"
|
2191 |
msgstr ""
|
2192 |
|
2193 |
+
#: src/admin-views/event-log.php:21
|
2194 |
+
msgid "Logging level"
|
2195 |
msgstr ""
|
2196 |
|
2197 |
+
#: src/admin-views/event-log.php:43
|
2198 |
+
msgid "Method"
|
2199 |
msgstr ""
|
2200 |
|
2201 |
+
#: src/admin-views/event-log.php:65
|
2202 |
+
msgid "View"
|
2203 |
msgstr ""
|
2204 |
|
2205 |
+
#: src/admin-views/event-log.php:100
|
2206 |
+
msgid "The selected log file is empty or has not been generated yet."
|
2207 |
msgstr ""
|
2208 |
|
2209 |
+
#: src/admin-views/event-log.php:117
|
2210 |
+
msgid "Download log"
|
2211 |
msgstr ""
|
2212 |
|
2213 |
+
#: src/admin-views/tribe-options-display.php:22
|
2214 |
+
msgid "Date Format Settings"
|
2215 |
msgstr ""
|
2216 |
|
2217 |
+
#: src/admin-views/tribe-options-display.php:28
|
2218 |
+
msgid ""
|
2219 |
+
"The following three fields accept the date format options available to the "
|
2220 |
+
"PHP %1$s function. <a href=\"%2$s\" target=\"_blank\">Learn how to make your "
|
2221 |
+
"own date format here</a>."
|
2222 |
msgstr ""
|
2223 |
|
2224 |
+
#: src/admin-views/tribe-options-display.php:36
|
2225 |
+
msgid "Datepicker Date Format"
|
2226 |
msgstr ""
|
2227 |
|
2228 |
+
#: src/admin-views/tribe-options-display.php:37
|
2229 |
+
msgid "Select the date format to use in datepickers"
|
2230 |
msgstr ""
|
2231 |
|
2232 |
+
#: src/admin-views/tribe-options-general.php:10
|
2233 |
+
msgid ""
|
2234 |
+
"Thank you for using Event Tickets! All of us at Modern Tribe sincerely "
|
2235 |
+
"appreciate your support and we're excited to see you using our plugins. "
|
2236 |
+
"Check out our handy %1$sNew User Primer%2$s to get started."
|
2237 |
msgstr ""
|
2238 |
|
2239 |
+
#: src/admin-views/tribe-options-general.php:15
|
2240 |
+
msgid ""
|
2241 |
+
"Optimize your site's event listings with %1$sThe Events Calendar%2$s, our "
|
2242 |
+
"free calendar plugin. Looking for additional functionality including "
|
2243 |
+
"recurring events, user-submission, advanced ticket sales and more? Check out "
|
2244 |
+
"our %3$spremium add-ons%4$s."
|
2245 |
msgstr ""
|
2246 |
|
2247 |
+
#: src/admin-views/tribe-options-general.php:20
|
2248 |
+
msgid ""
|
2249 |
+
"Looking for additional functionality including recurring events, custom "
|
2250 |
+
"meta, community events, ticket sales and more?"
|
2251 |
msgstr ""
|
2252 |
|
2253 |
+
#: src/admin-views/tribe-options-general.php:20
|
2254 |
+
msgid "Check out the available add-ons"
|
2255 |
msgstr ""
|
2256 |
|
2257 |
+
#: src/admin-views/tribe-options-general.php:25
|
2258 |
+
msgid "We hope our plugin is helping you out."
|
2259 |
msgstr ""
|
2260 |
|
2261 |
+
#: src/admin-views/tribe-options-general.php:30
|
2262 |
+
msgid ""
|
2263 |
+
"Are you thinking \"Wow, this plugin is amazing! I should say thanks to "
|
2264 |
+
"Modern Tribe for all their hard work.\" The greatest thanks we could ask for "
|
2265 |
+
"is recognition. Add a small text-only link at the bottom of your calendar "
|
2266 |
+
"pointing to The Events Calendar project."
|
2267 |
msgstr ""
|
2268 |
|
2269 |
+
#: src/admin-views/tribe-options-general.php:30
|
2270 |
+
msgid "See an example of the link"
|
2271 |
msgstr ""
|
2272 |
|
2273 |
+
#: src/admin-views/tribe-options-general.php:35
|
2274 |
+
msgid "Show The Events Calendar link"
|
2275 |
+
msgstr ""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2276 |
|
2277 |
+
#: src/admin-views/tribe-options-general.php:53
|
2278 |
+
msgid "Debug mode"
|
2279 |
+
msgstr ""
|
|
|
|
|
2280 |
|
2281 |
+
#: src/admin-views/tribe-options-general.php:59
|
2282 |
+
msgid ""
|
2283 |
+
"Enable this option to log debug information. By default this will log to "
|
2284 |
+
"your server PHP error log. If you'd like to see the log messages in your "
|
2285 |
+
"browser, then we recommend that you install the %s and look for the \"Tribe"
|
2286 |
+
"\" tab in the debug output."
|
2287 |
msgstr ""
|
2288 |
|
2289 |
+
#: src/admin-views/tribe-options-general.php:59
|
2290 |
+
msgid "Debug Bar Plugin"
|
|
|
2291 |
msgstr ""
|
2292 |
|
2293 |
+
#: src/admin-views/tribe-options-help.php:11
|
2294 |
+
msgid ""
|
2295 |
+
"Thanks you for using %s! All of us at Modern Tribe sincerely appreciate your "
|
2296 |
+
"support and we’re excited to see you using our plugins."
|
2297 |
msgstr ""
|
2298 |
|
2299 |
+
#: src/admin-views/tribe-options-help.php:14
|
2300 |
+
msgid "Getting Support"
|
2301 |
msgstr ""
|
2302 |
|
2303 |
+
#: src/admin-views/tribe-options-help.php:15
|
2304 |
+
msgid ""
|
2305 |
+
"Our website’s %s is a great place to find tips and tricks for using and "
|
2306 |
+
"customizing our plugins."
|
2307 |
msgstr ""
|
2308 |
|
2309 |
+
#: src/admin-views/tribe-options-help.php:15
|
2310 |
+
msgid "Knowledgebase"
|
2311 |
msgstr ""
|
2312 |
|
2313 |
+
#: src/admin-views/tribe-options-help.php:18
|
2314 |
+
msgid "Want to dive deeper?"
|
2315 |
msgstr ""
|
2316 |
|
2317 |
+
#: src/admin-views/tribe-options-help.php:20
|
2318 |
+
msgid "Check out our %s for developers."
|
2319 |
msgstr ""
|
2320 |
|
2321 |
+
#: src/admin-views/tribe-options-help.php:21
|
2322 |
+
msgid "list of available functions"
|
2323 |
msgstr ""
|
2324 |
|
2325 |
+
#: src/admin-views/tribe-options-help.php:26
|
2326 |
+
msgid "Getting More Help"
|
2327 |
msgstr ""
|
2328 |
|
2329 |
+
#: src/admin-views/tribe-options-help.php:27
|
2330 |
+
msgid ""
|
2331 |
+
"While the resources above help solve a majority of the issues we see, there "
|
2332 |
+
"are times you might be looking for extra support. If you need assistance "
|
2333 |
+
"using our plugins and would like us to take a look, please follow these "
|
2334 |
+
"steps:"
|
2335 |
msgstr ""
|
2336 |
|
2337 |
+
#: src/admin-views/tribe-options-help.php:31
|
2338 |
+
msgid ""
|
2339 |
+
"%s. All of the common (and not-so-common) answers to questions we see are "
|
2340 |
+
"here. It’s often the fastest path to finding an answer!"
|
2341 |
msgstr ""
|
2342 |
|
2343 |
+
#: src/admin-views/tribe-options-help.php:31
|
2344 |
+
msgid "Check our Knowledgebase"
|
2345 |
msgstr ""
|
2346 |
|
2347 |
+
#: src/admin-views/tribe-options-help.php:32
|
2348 |
+
msgid ""
|
2349 |
+
"%s. Testing for an existing conflict is the best start for in-depth "
|
2350 |
+
"troubleshooting. We will often ask you to follow these steps when opening a "
|
2351 |
+
"new thread, so doing this ahead of time will be super helpful."
|
2352 |
msgstr ""
|
2353 |
|
2354 |
+
#: src/admin-views/tribe-options-help.php:32
|
2355 |
+
msgid "Test for a theme or plugin conflict"
|
2356 |
msgstr ""
|
2357 |
|
2358 |
+
#: src/admin-views/tribe-options-help.php:33
|
2359 |
+
msgid ""
|
2360 |
+
"%s. There are very few issues we haven’t seen and it’s likely another user "
|
2361 |
+
"has already asked your question and gotten an answer from our support staff. "
|
2362 |
+
"While posting to the help desk is open only to paid customers, they are open "
|
2363 |
+
"for anyone to search and review."
|
2364 |
msgstr ""
|
2365 |
|
2366 |
+
#: src/admin-views/tribe-options-help.php:33
|
2367 |
+
msgid "Search our support help desk"
|
2368 |
msgstr ""
|
2369 |
|
2370 |
+
#: src/admin-views/tribe-options-help.php:37
|
2371 |
+
msgid ""
|
2372 |
+
"Please note that all hands-on support is provided via the help desk. You can "
|
2373 |
+
"email or tweet at us… but we will probably point you back to the help desk 😄"
|
2374 |
msgstr ""
|
2375 |
|
2376 |
+
#: src/admin-views/tribe-options-help.php:38
|
2377 |
+
msgid "Read more about our support policy"
|
2378 |
msgstr ""
|
2379 |
|
2380 |
+
#: src/admin-views/tribe-options-help.php:41
|
2381 |
+
msgid "System Information"
|
2382 |
msgstr ""
|
2383 |
|
2384 |
+
#: src/admin-views/tribe-options-help.php:42
|
2385 |
+
msgid ""
|
2386 |
+
"The details of your calendar plugin and settings is often needed for you or "
|
2387 |
+
"our staff to help troubleshoot an issue. Please opt-in below to "
|
2388 |
+
"automatically share your system information with our support team. This will "
|
2389 |
+
"allow us to assist you faster if you post in our help desk."
|
2390 |
msgstr ""
|
2391 |
|
2392 |
+
#: src/admin-views/tribe-options-help.php:52
|
2393 |
+
msgid "Recent Template Changes"
|
2394 |
msgstr ""
|
2395 |
|
2396 |
+
#: src/admin-views/tribe-options-help.php:55
|
2397 |
+
msgid "Event Log"
|
2398 |
msgstr ""
|
2399 |
|
2400 |
+
#: src/admin-views/tribe-options-help.php:74
|
2401 |
+
msgid "News and Tutorials"
|
2402 |
msgstr ""
|
2403 |
|
2404 |
+
#: src/admin-views/tribe-options-help.php:80
|
2405 |
+
msgid "More..."
|
2406 |
msgstr ""
|
2407 |
|
2408 |
+
#: src/admin-views/tribe-options-licenses.php:11
|
2409 |
+
#: src/admin-views/tribe-options-licenses.php:16
|
2410 |
+
msgid " (opens in new window)"
|
2411 |
msgstr ""
|
2412 |
|
2413 |
+
#: src/admin-views/tribe-options-licenses.php:15
|
2414 |
+
msgid ""
|
2415 |
+
"The license key you received when completing your purchase from %1$s will "
|
2416 |
+
"grant you access to support and updates until it expires. You do not need to "
|
2417 |
+
"enter the key below for the plugins to work, but you will need to enter it "
|
2418 |
+
"to get automatic updates. %3$sFind your license keys at %2$s%4$s."
|
2419 |
msgstr ""
|
2420 |
|
2421 |
+
#: src/admin-views/tribe-options-licenses.php:22
|
2422 |
+
msgid ""
|
2423 |
+
"Each paid add-on has its own unique license key. Simply paste the key into "
|
2424 |
+
"its appropriate field below, and give it a moment to validate. You know "
|
2425 |
+
"you're set when a green expiration date appears alongside a \"valid\" "
|
2426 |
+
"message."
|
2427 |
msgstr ""
|
2428 |
|
2429 |
+
#: src/admin-views/tribe-options-licenses.php:25
|
2430 |
+
msgid ""
|
2431 |
+
"If you're seeing a red message telling you that your key isn't valid or is "
|
2432 |
+
"out of installs, visit %1$s to manage your installs or renew / upgrade your "
|
2433 |
+
"license."
|
2434 |
msgstr ""
|
2435 |
|
2436 |
+
#: src/admin-views/tribe-options-licenses.php:30
|
2437 |
+
msgid ""
|
2438 |
+
"Not seeing an update but expecting one? In WordPress, go to %1$sDashboard > "
|
2439 |
+
"Updates%2$s and click \"Check Again\"."
|
2440 |
msgstr ""
|
2441 |
|
2442 |
+
#: src/admin-views/tribe-options-licenses.php:38
|
2443 |
+
msgid ""
|
2444 |
+
"%1$s Using our plugins in a multisite network? %2$s Please note that your "
|
2445 |
+
"license key will be applied to the entire network, not just this site."
|
2446 |
msgstr ""
|
2447 |
|
2448 |
+
#: src/admin-views/tribe-options-licenses.php:47
|
2449 |
+
msgid ""
|
2450 |
+
"Only license fields for %1$snetwork activated%2$s plugins will be listed on "
|
2451 |
+
"this screen. "
|
2452 |
msgstr ""
|
2453 |
|
2454 |
+
#: src/admin-views/tribe-options-network.php:15
|
2455 |
+
msgid "Network Settings"
|
2456 |
msgstr ""
|
2457 |
|
2458 |
+
#: src/admin-views/tribe-options-network.php:19
|
2459 |
+
msgid ""
|
2460 |
+
"This is where all of the global network settings for Modern Tribe's The "
|
2461 |
+
"Events Calendar can be modified."
|
2462 |
msgstr ""
|
2463 |
|
2464 |
+
#: src/admin-views/tribe-options-network.php:27
|
2465 |
+
msgid "Hide the following settings tabs on every site:"
|
2466 |
msgstr ""
|
2467 |
|
2468 |
+
#: vendor/a5hleyrich/wp-background-processing/classes/wp-background-process.php:425
|
2469 |
+
msgid "Every %d Minutes"
|
2470 |
msgstr ""
|
2471 |
|
2472 |
+
#. Plugin Name of the plugin/theme
|
2473 |
+
msgid "Tribe Common"
|
2474 |
msgstr ""
|
2475 |
|
2476 |
+
#. Description of the plugin/theme
|
2477 |
+
msgid "An event settings framework for managing shared options"
|
2478 |
msgstr ""
|
2479 |
|
2480 |
+
#. Author of the plugin/theme
|
2481 |
+
msgid "Modern Tribe, Inc."
|
2482 |
msgstr ""
|
2483 |
|
2484 |
+
#. Author URI of the plugin/theme
|
2485 |
+
msgid "http://m.tri.be/1x"
|
2486 |
msgstr ""
|
common/readme.txt
CHANGED
@@ -2,6 +2,13 @@
|
|
2 |
|
3 |
== Changelog ==
|
4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
= [4.7.11] 2018-04-18 =
|
6 |
|
7 |
* Fix - Restore "type" attribute to some inline `<script>` tags to ensure proper character encoding in Customizer-generated CSS [103167]
|
2 |
|
3 |
== Changelog ==
|
4 |
|
5 |
+
= [4.7.12] 2018-05-09 =
|
6 |
+
|
7 |
+
* Fix - Updated datatables.js to its most recent version to prevent conflicts [102465]
|
8 |
+
* Tweak - Added the `Tribe__Process__Queue` class to handle background processing operations
|
9 |
+
* Tweak - Changed 'forums' to 'help desk' throughout the content in the "Help" tab [104561]
|
10 |
+
* Language - 3 new strings added, 84 updated, 3 fuzzied, and 3 obsoleted
|
11 |
+
|
12 |
= [4.7.11] 2018-04-18 =
|
13 |
|
14 |
* Fix - Restore "type" attribute to some inline `<script>` tags to ensure proper character encoding in Customizer-generated CSS [103167]
|
common/src/Tribe/Context.php
CHANGED
@@ -85,7 +85,7 @@ class Tribe__Context {
|
|
85 |
* This method exists to allow us test code that behaves differently depending on the execution
|
86 |
* context; passing a value to this argument will set it to that value in future checks, a test-related usage.
|
87 |
*
|
88 |
-
* @since
|
89 |
*
|
90 |
* @param bool $doing_ajax An injectable status to override the `DOING_AJAX` check.
|
91 |
*
|
85 |
* This method exists to allow us test code that behaves differently depending on the execution
|
86 |
* context; passing a value to this argument will set it to that value in future checks, a test-related usage.
|
87 |
*
|
88 |
+
* @since 4.7.12
|
89 |
*
|
90 |
* @param bool $doing_ajax An injectable status to override the `DOING_AJAX` check.
|
91 |
*
|
common/src/Tribe/Date_Utils.php
CHANGED
@@ -18,6 +18,7 @@ if ( ! class_exists( 'Tribe__Date_Utils' ) ) {
|
|
18 |
const MERIDIANFORMAT = 'A';
|
19 |
const DBDATEFORMAT = 'Y-m-d';
|
20 |
const DBDATETIMEFORMAT = 'Y-m-d H:i:s';
|
|
|
21 |
const DBTIMEFORMAT = 'H:i:s';
|
22 |
const DBYEARMONTHTIMEFORMAT = 'Y-m';
|
23 |
|
18 |
const MERIDIANFORMAT = 'A';
|
19 |
const DBDATEFORMAT = 'Y-m-d';
|
20 |
const DBDATETIMEFORMAT = 'Y-m-d H:i:s';
|
21 |
+
const DBTZDATETIMEFORMAT = 'Y-m-d H:i:s O';
|
22 |
const DBTIMEFORMAT = 'H:i:s';
|
23 |
const DBYEARMONTHTIMEFORMAT = 'Y-m';
|
24 |
|
common/src/Tribe/Db.php
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Class Tribe__Db
|
5 |
+
*
|
6 |
+
* Provides information about the database settings.
|
7 |
+
*/
|
8 |
+
class Tribe__Db {
|
9 |
+
|
10 |
+
/**
|
11 |
+
* Gets the value of the `max_allowed_packet` setting.
|
12 |
+
*
|
13 |
+
* @since 4.7.12
|
14 |
+
*
|
15 |
+
* @return int
|
16 |
+
*
|
17 |
+
* @link https://dev.mysql.com/doc/refman/5.7/en/packet-too-large.html
|
18 |
+
*/
|
19 |
+
public function get_max_allowed_packet_size() {
|
20 |
+
/** @var wpdb $wpdb */
|
21 |
+
global $wpdb;
|
22 |
+
|
23 |
+
$max_size = $wpdb->get_results( "SHOW VARIABLES LIKE 'max_allowed_packet';", ARRAY_A );
|
24 |
+
// default the size to 1MB
|
25 |
+
$max_size = ! empty( $max_size[0]['Value'] ) ? $max_size[0]['Value'] : 1048576;
|
26 |
+
|
27 |
+
/**
|
28 |
+
* Filters the size of the `max_allowed_packet` setting in bytes.
|
29 |
+
*
|
30 |
+
* @since 4.7.12
|
31 |
+
*
|
32 |
+
* @param int $max_size By default the `max_allowed_packet` from the database.
|
33 |
+
*/
|
34 |
+
$max_size = apply_filters( 'tribe_db_max_allowed_packet', $max_size );
|
35 |
+
|
36 |
+
return $max_size;
|
37 |
+
}
|
38 |
+
}
|
common/src/Tribe/JSON_LD/Abstract.php
CHANGED
@@ -31,7 +31,7 @@ abstract class Tribe__JSON_LD__Abstract {
|
|
31 |
/**
|
32 |
* Holder for a post when it has multiple types
|
33 |
*
|
34 |
-
* @since
|
35 |
*
|
36 |
* @var array
|
37 |
*/
|
@@ -270,7 +270,7 @@ abstract class Tribe__JSON_LD__Abstract {
|
|
270 |
/**
|
271 |
* Public method to have access to the types
|
272 |
*
|
273 |
-
* @since
|
274 |
*
|
275 |
* @return array
|
276 |
*/
|
@@ -281,7 +281,7 @@ abstract class Tribe__JSON_LD__Abstract {
|
|
281 |
/**
|
282 |
* Register the current $type to prevent duplicates entries with different $types and IDs
|
283 |
*
|
284 |
-
* @since
|
285 |
*
|
286 |
* @param $post
|
287 |
* @param $type
|
@@ -326,7 +326,7 @@ abstract class Tribe__JSON_LD__Abstract {
|
|
326 |
/**
|
327 |
* Return `true` if the $type has been already registered for the specified $id.
|
328 |
*
|
329 |
-
* @since
|
330 |
*
|
331 |
* @param $id
|
332 |
* @param $type
|
31 |
/**
|
32 |
* Holder for a post when it has multiple types
|
33 |
*
|
34 |
+
* @since 4.7.12
|
35 |
*
|
36 |
* @var array
|
37 |
*/
|
270 |
/**
|
271 |
* Public method to have access to the types
|
272 |
*
|
273 |
+
* @since 4.7.12
|
274 |
*
|
275 |
* @return array
|
276 |
*/
|
281 |
/**
|
282 |
* Register the current $type to prevent duplicates entries with different $types and IDs
|
283 |
*
|
284 |
+
* @since 4.7.12
|
285 |
*
|
286 |
* @param $post
|
287 |
* @param $type
|
326 |
/**
|
327 |
* Return `true` if the $type has been already registered for the specified $id.
|
328 |
*
|
329 |
+
* @since 4.7.12
|
330 |
*
|
331 |
* @param $id
|
332 |
* @param $type
|
common/src/Tribe/Languages/Locations.php
CHANGED
@@ -303,7 +303,7 @@ class Tribe__Languages__Locations {
|
|
303 |
/**
|
304 |
* Filter that allows to change the list and the output of the countries names.
|
305 |
*
|
306 |
-
* @since
|
307 |
*
|
308 |
* @param array associative array with: Country Code => Country Name
|
309 |
*/
|
@@ -380,7 +380,7 @@ class Tribe__Languages__Locations {
|
|
380 |
/**
|
381 |
* Filter that allows to change the names of US states before output.
|
382 |
*
|
383 |
-
* @since
|
384 |
*
|
385 |
* @param array Associative array with the format: State Code => State Name
|
386 |
*/
|
303 |
/**
|
304 |
* Filter that allows to change the list and the output of the countries names.
|
305 |
*
|
306 |
+
* @since 4.7.12
|
307 |
*
|
308 |
* @param array associative array with: Country Code => Country Name
|
309 |
*/
|
380 |
/**
|
381 |
* Filter that allows to change the names of US states before output.
|
382 |
*
|
383 |
+
* @since 4.7.12
|
384 |
*
|
385 |
* @param array Associative array with the format: State Code => State Name
|
386 |
*/
|
common/src/Tribe/Main.php
CHANGED
@@ -17,7 +17,7 @@ class Tribe__Main {
|
|
17 |
const OPTIONNAME = 'tribe_events_calendar_options';
|
18 |
const OPTIONNAMENETWORK = 'tribe_events_calendar_network_options';
|
19 |
|
20 |
-
const VERSION = '4.7.
|
21 |
|
22 |
const FEED_URL = 'https://theeventscalendar.com/feed/';
|
23 |
|
@@ -171,21 +171,13 @@ class Tribe__Main {
|
|
171 |
array(
|
172 |
array( 'tribe-accessibility-css', 'accessibility.css' ),
|
173 |
array( 'tribe-clipboard', 'vendor/clipboard/clipboard.js' ),
|
174 |
-
array( 'datatables', 'vendor/datatables/
|
175 |
array( 'tribe-select2', 'vendor/tribe-select2/select2.js', array( 'jquery' ) ),
|
176 |
array( 'tribe-select2-css', 'vendor/tribe-select2/select2.css' ),
|
177 |
array( 'tribe-utils-camelcase', 'utils-camelcase.js', array( 'underscore' ) ),
|
178 |
array( 'tribe-moment', 'vendor/momentjs/moment.js' ),
|
179 |
array( 'datatables-css', 'datatables.css' ),
|
180 |
-
array( 'datatables
|
181 |
-
array( 'datatables-responsive-css', 'vendor/datatables/extensions/Responsive/css/responsive.dataTables.css' ),
|
182 |
-
array( 'datatables-select', 'vendor/datatables/extensions/Select/js/dataTables.select.js', array( 'jquery', 'datatables' ) ),
|
183 |
-
array( 'datatables-select-css', 'vendor/datatables/extensions/Select/css/select.dataTables.css' ),
|
184 |
-
array( 'datatables-scroller', 'vendor/datatables/extensions/Scroller/js/dataTables.scroller.js', array( 'jquery', 'datatables' ) ),
|
185 |
-
array( 'datatables-scroller-css', 'vendor/datatables/extensions/Scroller/css/scroller.dataTables.css' ),
|
186 |
-
array( 'datatables-fixedheader', 'vendor/datatables/extensions/FixedHeader/js/dataTables.fixedHeader.js', array( 'jquery', 'datatables' ) ),
|
187 |
-
array( 'datatables-fixedheader-css', 'vendor/datatables/extensions/FixedHeader/css/fixedHeader.dataTables.css' ),
|
188 |
-
array( 'tribe-datatables', 'tribe-datatables.js', array( 'datatables', 'datatables-select' ) ),
|
189 |
array( 'tribe-bumpdown', 'bumpdown.js', array( 'jquery', 'underscore', 'hoverIntent' ) ),
|
190 |
array( 'tribe-bumpdown-css', 'bumpdown.css' ),
|
191 |
array( 'tribe-buttonset-style', 'buttonset.css' ),
|
@@ -476,7 +468,7 @@ class Tribe__Main {
|
|
476 |
*
|
477 |
* @param bool $doing_ajax An injectable status to override the `DOING_AJAX` check.
|
478 |
*
|
479 |
-
* @deprecated
|
480 |
*
|
481 |
* @return boolean
|
482 |
*/
|
@@ -500,6 +492,7 @@ class Tribe__Main {
|
|
500 |
* Runs tribe_plugins_loaded action, should be hooked to the end of plugins_loaded
|
501 |
*/
|
502 |
public function tribe_plugins_loaded() {
|
|
|
503 |
/**
|
504 |
* Runs after all plugins including Tribe ones have loaded
|
505 |
*
|
@@ -530,11 +523,10 @@ class Tribe__Main {
|
|
530 |
tribe_singleton( 'post-duplicate', 'Tribe__Duplicate__Post' );
|
531 |
tribe_singleton( 'context', 'Tribe__Context' );
|
532 |
tribe_singleton( 'post-transient', 'Tribe__Post_Transient' );
|
|
|
533 |
|
534 |
tribe_singleton( 'callback', 'Tribe__Utils__Callback' );
|
535 |
tribe_singleton( 'pue.notices', 'Tribe__PUE__Notices' );
|
536 |
-
|
537 |
-
tribe()->register( 'Tribe__Service_Providers__Processes' );
|
538 |
}
|
539 |
|
540 |
/************************
|
17 |
const OPTIONNAME = 'tribe_events_calendar_options';
|
18 |
const OPTIONNAMENETWORK = 'tribe_events_calendar_network_options';
|
19 |
|
20 |
+
const VERSION = '4.7.12';
|
21 |
|
22 |
const FEED_URL = 'https://theeventscalendar.com/feed/';
|
23 |
|
171 |
array(
|
172 |
array( 'tribe-accessibility-css', 'accessibility.css' ),
|
173 |
array( 'tribe-clipboard', 'vendor/clipboard/clipboard.js' ),
|
174 |
+
array( 'datatables', 'vendor/datatables/datatables.js', array( 'jquery' ) ),
|
175 |
array( 'tribe-select2', 'vendor/tribe-select2/select2.js', array( 'jquery' ) ),
|
176 |
array( 'tribe-select2-css', 'vendor/tribe-select2/select2.css' ),
|
177 |
array( 'tribe-utils-camelcase', 'utils-camelcase.js', array( 'underscore' ) ),
|
178 |
array( 'tribe-moment', 'vendor/momentjs/moment.js' ),
|
179 |
array( 'datatables-css', 'datatables.css' ),
|
180 |
+
array( 'tribe-datatables', 'tribe-datatables.js', array( 'datatables' ) ),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
181 |
array( 'tribe-bumpdown', 'bumpdown.js', array( 'jquery', 'underscore', 'hoverIntent' ) ),
|
182 |
array( 'tribe-bumpdown-css', 'bumpdown.css' ),
|
183 |
array( 'tribe-buttonset-style', 'buttonset.css' ),
|
468 |
*
|
469 |
* @param bool $doing_ajax An injectable status to override the `DOING_AJAX` check.
|
470 |
*
|
471 |
+
* @deprecated 4.7.12
|
472 |
*
|
473 |
* @return boolean
|
474 |
*/
|
492 |
* Runs tribe_plugins_loaded action, should be hooked to the end of plugins_loaded
|
493 |
*/
|
494 |
public function tribe_plugins_loaded() {
|
495 |
+
tribe_register_provider( 'Tribe__Service_Providers__Processes' );
|
496 |
/**
|
497 |
* Runs after all plugins including Tribe ones have loaded
|
498 |
*
|
523 |
tribe_singleton( 'post-duplicate', 'Tribe__Duplicate__Post' );
|
524 |
tribe_singleton( 'context', 'Tribe__Context' );
|
525 |
tribe_singleton( 'post-transient', 'Tribe__Post_Transient' );
|
526 |
+
tribe_singleton( 'db', 'Tribe__Db' );
|
527 |
|
528 |
tribe_singleton( 'callback', 'Tribe__Utils__Callback' );
|
529 |
tribe_singleton( 'pue.notices', 'Tribe__PUE__Notices' );
|
|
|
|
|
530 |
}
|
531 |
|
532 |
/************************
|
common/src/Tribe/Meta/Chunker.php
CHANGED
@@ -439,10 +439,8 @@ class Tribe__Meta__Chunker {
|
|
439 |
if ( ! empty( $this->max_chunk_size ) ) {
|
440 |
return $this->max_chunk_size;
|
441 |
}
|
442 |
-
|
443 |
-
|
444 |
-
$max_size = $wpdb->get_results( "SHOW VARIABLES LIKE 'max_allowed_packet';", ARRAY_A );
|
445 |
-
$max_size = ! empty( $max_size[0]['Value'] ) ? $max_size[0]['Value'] : 1048576;
|
446 |
|
447 |
/**
|
448 |
* Filters the max size of the of the chunks in bytes.
|
439 |
if ( ! empty( $this->max_chunk_size ) ) {
|
440 |
return $this->max_chunk_size;
|
441 |
}
|
442 |
+
|
443 |
+
$max_size = tribe( 'db' )->get_max_allowed_packet_size();
|
|
|
|
|
444 |
|
445 |
/**
|
446 |
* Filters the max size of the of the chunks in bytes.
|
common/src/Tribe/Process/Handler.php
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
*
|
6 |
* The base class for all Modern Tribe async process handlers.
|
7 |
*
|
8 |
-
* @since
|
9 |
*
|
10 |
* @see Tribe__Service_Providers__Processes for more insight about this class utility.
|
11 |
*/
|
@@ -18,7 +18,7 @@ abstract class Tribe__Process__Handler extends WP_Async_Request {
|
|
18 |
/**
|
19 |
* Tribe__Process__Handler constructor.
|
20 |
*
|
21 |
-
* @since
|
22 |
*/
|
23 |
public function __construct() {
|
24 |
$class = get_class( $this );
|
@@ -29,27 +29,28 @@ abstract class Tribe__Process__Handler extends WP_Async_Request {
|
|
29 |
/**
|
30 |
* Returns the async process action name.
|
31 |
*
|
32 |
-
*
|
|
|
|
|
33 |
*
|
34 |
* @return string
|
|
|
|
|
35 |
*/
|
36 |
-
|
|
|
|
|
|
|
37 |
|
38 |
/**
|
39 |
-
* Handles the
|
40 |
*
|
41 |
-
*
|
42 |
-
* This method is an alias of the publicly accessible `handle_request` one.
|
43 |
-
*
|
44 |
-
* @since TBD
|
45 |
*
|
46 |
* @param array|null $data_source If not provided the method will read the handler data from the
|
47 |
-
*
|
48 |
*
|
49 |
* @return mixed
|
50 |
-
*
|
51 |
-
* @see tribe_upload_image()
|
52 |
-
* @see Tribe__Process__Post_Thumbnail_Setter::sync_handle()
|
53 |
*/
|
54 |
abstract public function sync_handle( array $data_source = null );
|
55 |
|
@@ -57,7 +58,7 @@ abstract class Tribe__Process__Handler extends WP_Async_Request {
|
|
57 |
* Overrides the base `dispatch` method to allow for constants and/or environment vars to run
|
58 |
* async requests in sync mode.
|
59 |
*
|
60 |
-
* @since
|
61 |
*
|
62 |
* @return mixed
|
63 |
*/
|
5 |
*
|
6 |
* The base class for all Modern Tribe async process handlers.
|
7 |
*
|
8 |
+
* @since 4.7.12
|
9 |
*
|
10 |
* @see Tribe__Service_Providers__Processes for more insight about this class utility.
|
11 |
*/
|
18 |
/**
|
19 |
* Tribe__Process__Handler constructor.
|
20 |
*
|
21 |
+
* @since 4.7.12
|
22 |
*/
|
23 |
public function __construct() {
|
24 |
$class = get_class( $this );
|
29 |
/**
|
30 |
* Returns the async process action name.
|
31 |
*
|
32 |
+
* Extending classes must override this method to return their unique action slug.
|
33 |
+
*
|
34 |
+
* @since 4.7.12
|
35 |
*
|
36 |
* @return string
|
37 |
+
*
|
38 |
+
* @throws RuntimeException If the extending class does not override this method.
|
39 |
*/
|
40 |
+
public static function action() {
|
41 |
+
$class = get_called_class();
|
42 |
+
throw new RuntimeException( "Class {$class} should override the `action` method to define its own unique identifier." );
|
43 |
+
}
|
44 |
|
45 |
/**
|
46 |
+
* Handles the process immediately, not in an async manner.
|
47 |
*
|
48 |
+
* @since 4.7.12
|
|
|
|
|
|
|
49 |
*
|
50 |
* @param array|null $data_source If not provided the method will read the handler data from the
|
51 |
+
* request array.
|
52 |
*
|
53 |
* @return mixed
|
|
|
|
|
|
|
54 |
*/
|
55 |
abstract public function sync_handle( array $data_source = null );
|
56 |
|
58 |
* Overrides the base `dispatch` method to allow for constants and/or environment vars to run
|
59 |
* async requests in sync mode.
|
60 |
*
|
61 |
+
* @since 4.7.12
|
62 |
*
|
63 |
* @return mixed
|
64 |
*/
|
common/src/Tribe/Process/Post_Thumbnail_Setter.php
CHANGED
@@ -11,7 +11,7 @@
|
|
11 |
* $post_thumbnail_setter->set_post_thumbnail( 'http://foo.com/random-image.jpg' );
|
12 |
* $post_thumbnail_setter->dispatch();
|
13 |
*
|
14 |
-
* @since
|
15 |
*/
|
16 |
class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
17 |
/**
|
@@ -41,7 +41,7 @@ class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
|
41 |
throw new InvalidArgumentException( 'Post ID and featured image should be set before trying to dispatch.' );
|
42 |
}
|
43 |
|
44 |
-
$this->data( array( 'post_id' => $this->post_id, 'post_thumbnail' => $this->post_thumbnail ) );
|
45 |
|
46 |
return parent::dispatch();
|
47 |
}
|
@@ -50,7 +50,7 @@ class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
|
50 |
* Sets the ID of the post the post thumbnail (aka "featured image") should be attached
|
51 |
* and set for.
|
52 |
*
|
53 |
-
* @since
|
54 |
*
|
55 |
* @param int $post_id The target post ID.
|
56 |
*/
|
@@ -61,7 +61,7 @@ class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
|
61 |
/**
|
62 |
* Sets the post thumbnail ID or source the process should set.
|
63 |
*
|
64 |
-
* @since
|
65 |
*
|
66 |
* @param int|string $post_thumbnail Either an attachment ID or the full URL, or path, to
|
67 |
* the post thumbnail image.
|
@@ -76,7 +76,7 @@ class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
|
76 |
* The post thumbnail will be uploaded, if not uploaded already, using the `tribe_upload_image` function.
|
77 |
* This method is an alias of the publicly accessible `sync_handle` one.
|
78 |
*
|
79 |
-
* @since
|
80 |
*
|
81 |
* @see tribe_upload_image()
|
82 |
* @see Tribe__Process__Post_Thumbnail_Setter::sync_handle()
|
11 |
* $post_thumbnail_setter->set_post_thumbnail( 'http://foo.com/random-image.jpg' );
|
12 |
* $post_thumbnail_setter->dispatch();
|
13 |
*
|
14 |
+
* @since 4.7.12
|
15 |
*/
|
16 |
class Tribe__Process__Post_Thumbnail_Setter extends Tribe__Process__Handler {
|
17 |
/**
|
41 |
throw new InvalidArgumentException( 'Post ID and featured image should be set before trying to dispatch.' );
|
42 |
}
|
43 |
|
44 |
+
$this->data( array( 'post_id' => $this->post_id, 'post_thumbnail' => trim( $this->post_thumbnail ) ) );
|
45 |
|
46 |
return parent::dispatch();
|
47 |
}
|
50 |
* Sets the ID of the post the post thumbnail (aka "featured image") should be attached
|
51 |
* and set for.
|
52 |
*
|
53 |
+
* @since 4.7.12
|
54 |
*
|
55 |
* @param int $post_id The target post ID.
|
56 |
*/
|
61 |
/**
|
62 |
* Sets the post thumbnail ID or source the process should set.
|
63 |
*
|
64 |
+
* @since 4.7.12
|
65 |
*
|
66 |
* @param int|string $post_thumbnail Either an attachment ID or the full URL, or path, to
|
67 |
* the post thumbnail image.
|
76 |
* The post thumbnail will be uploaded, if not uploaded already, using the `tribe_upload_image` function.
|
77 |
* This method is an alias of the publicly accessible `sync_handle` one.
|
78 |
*
|
79 |
+
* @since 4.7.12
|
80 |
*
|
81 |
* @see tribe_upload_image()
|
82 |
* @see Tribe__Process__Post_Thumbnail_Setter::sync_handle()
|
common/src/Tribe/Process/Queue.php
ADDED
@@ -0,0 +1,451 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Class Tribe__Process__Queue
|
5 |
+
*
|
6 |
+
* @since 4.7.12
|
7 |
+
*
|
8 |
+
* The base class to process queues asynchronously.
|
9 |
+
*/
|
10 |
+
abstract class Tribe__Process__Queue extends WP_Background_Process {
|
11 |
+
|
12 |
+
/**
|
13 |
+
* @var string The common identified prefix to all our async process handlers.
|
14 |
+
*/
|
15 |
+
protected $prefix = 'tribe_queue';
|
16 |
+
|
17 |
+
/**
|
18 |
+
* @var string The base that should be used to build the queue id.
|
19 |
+
*/
|
20 |
+
protected $id_base;
|
21 |
+
|
22 |
+
/**
|
23 |
+
* @var string The queue unique identifier
|
24 |
+
*/
|
25 |
+
protected $id;
|
26 |
+
|
27 |
+
/**
|
28 |
+
* @var int How many items this instance processed.
|
29 |
+
*/
|
30 |
+
protected $done = 0;
|
31 |
+
|
32 |
+
/**
|
33 |
+
* @var int
|
34 |
+
*/
|
35 |
+
protected $original_batch_count = 0;
|
36 |
+
|
37 |
+
/**
|
38 |
+
* @var int The maximum size of a fragment in bytes.
|
39 |
+
*/
|
40 |
+
protected $max_frag_size;
|
41 |
+
|
42 |
+
/**
|
43 |
+
* @var bool Whether the current handling is sync or not.
|
44 |
+
*/
|
45 |
+
protected $doing_sync = false;
|
46 |
+
|
47 |
+
/**
|
48 |
+
* @var bool Whether the queue `save` method was already called or not.
|
49 |
+
*/
|
50 |
+
protected $did_save = false;
|
51 |
+
|
52 |
+
/**
|
53 |
+
* @var string The batch key used by the queue.
|
54 |
+
*/
|
55 |
+
protected $batch_key;
|
56 |
+
|
57 |
+
/**
|
58 |
+
* {@inheritdoc}
|
59 |
+
*/
|
60 |
+
public function __construct() {
|
61 |
+
$class = get_class( $this );
|
62 |
+
$this->action = $class::action();
|
63 |
+
parent::__construct();
|
64 |
+
}
|
65 |
+
|
66 |
+
/**
|
67 |
+
* Stops a queue that might be running.
|
68 |
+
*
|
69 |
+
* The queue process results are not rolled back (e.g. 200 posts to create, stopped
|
70 |
+
* after 50, those 50 posts will persist).
|
71 |
+
*
|
72 |
+
* @since 4.7.12
|
73 |
+
*
|
74 |
+
* @param string $queue_id The unique identifier of the queue that should be stopped.
|
75 |
+
*
|
76 |
+
* @see Tribe__Process__Queue::save() to get the queue unique id.
|
77 |
+
*/
|
78 |
+
public static function stop_queue( $queue_id ) {
|
79 |
+
$meta = (array) get_transient( $queue_id . '_meta' );
|
80 |
+
delete_transient( $queue_id . '_meta' );
|
81 |
+
|
82 |
+
if ( ! empty( $meta['identifier'] ) ) {
|
83 |
+
delete_site_transient( $meta['identifier'] . '_process_lock' );
|
84 |
+
}
|
85 |
+
|
86 |
+
return delete_site_option( $queue_id );
|
87 |
+
}
|
88 |
+
|
89 |
+
/**
|
90 |
+
* Returns a queue status and information.
|
91 |
+
*
|
92 |
+
* @since 4.7.12
|
93 |
+
*
|
94 |
+
* @param string $queue_id
|
95 |
+
*
|
96 |
+
* @return Tribe__Data An object containing information about the queue.
|
97 |
+
*
|
98 |
+
* @see Tribe__Process__Queue::save() to get the queue unique id.
|
99 |
+
*/
|
100 |
+
public static function get_status_of( $queue_id ) {
|
101 |
+
$meta = (array) get_transient( $queue_id . '_meta' );
|
102 |
+
$data = array(
|
103 |
+
'identifier' => $queue_id,
|
104 |
+
'done' => (int) Tribe__Utils__Array::get( $meta, 'done', 0 ),
|
105 |
+
'total' => (int) Tribe__Utils__Array::get( $meta, 'total', 0 ),
|
106 |
+
'fragments' => (int) Tribe__Utils__Array::get( $meta, 'fragments', 0 ),
|
107 |
+
);
|
108 |
+
|
109 |
+
return new Tribe__Data( $data, 0 );
|
110 |
+
}
|
111 |
+
|
112 |
+
/**
|
113 |
+
* Returns the async process action name.
|
114 |
+
*
|
115 |
+
* Extending classes must override this method to return their unique action slug.
|
116 |
+
*
|
117 |
+
* @since 4.7.12
|
118 |
+
*
|
119 |
+
* @return string
|
120 |
+
*
|
121 |
+
* @throws RuntimeException If the extending class does not override this method.
|
122 |
+
*/
|
123 |
+
public static function action() {
|
124 |
+
$class = get_called_class();
|
125 |
+
throw new RuntimeException( "Class {$class} should override the `action` method to define its own unique identifier." );
|
126 |
+
}
|
127 |
+
|
128 |
+
/**
|
129 |
+
* {@inheritdoc}
|
130 |
+
*/
|
131 |
+
public function delete( $key ) {
|
132 |
+
global $wpdb;
|
133 |
+
|
134 |
+
$meta_key = $this->get_meta_key( $key );
|
135 |
+
|
136 |
+
$table = $wpdb->options;
|
137 |
+
$column = 'option_name';
|
138 |
+
|
139 |
+
if ( is_multisite() ) {
|
140 |
+
$table = $wpdb->sitemeta;
|
141 |
+
$column = 'meta_key';
|
142 |
+
}
|
143 |
+
|
144 |
+
$key = $wpdb->esc_like( $key ) . '%';
|
145 |
+
|
146 |
+
$wpdb->query( $wpdb->prepare( "
|
147 |
+
DELETE
|
148 |
+
FROM {$table}
|
149 |
+
WHERE {$column} LIKE %s
|
150 |
+
", $key ) );
|
151 |
+
|
152 |
+
delete_transient( $meta_key );
|
153 |
+
|
154 |
+
return $this;
|
155 |
+
}
|
156 |
+
|
157 |
+
/**
|
158 |
+
* {@inheritdoc}
|
159 |
+
*/
|
160 |
+
public function update( $key, $data ) {
|
161 |
+
$meta_key = $this->get_meta_key( $key );
|
162 |
+
$meta = (array) get_transient( $meta_key );
|
163 |
+
$done = $this->original_batch_count - count( $data );
|
164 |
+
|
165 |
+
$update_data = array_merge( $meta, array(
|
166 |
+
'done' => $meta['done'] + $done,
|
167 |
+
) );
|
168 |
+
|
169 |
+
/**
|
170 |
+
* Filters the information that will be updated in the database for this queue type.
|
171 |
+
*
|
172 |
+
* @since 4.7.12
|
173 |
+
*
|
174 |
+
* @param array $update_data
|
175 |
+
* @param self $this
|
176 |
+
*/
|
177 |
+
$update_data = apply_filters( "tribe_process_queue_{$this->identifier}_update_data", $update_data, $this );
|
178 |
+
|
179 |
+
set_transient( $meta_key, $update_data );
|
180 |
+
|
181 |
+
return parent::update( $key, $data );
|
182 |
+
}
|
183 |
+
|
184 |
+
/**
|
185 |
+
* {@inheritdoc}
|
186 |
+
*/
|
187 |
+
public function save() {
|
188 |
+
$key = $this->generate_key();
|
189 |
+
|
190 |
+
$fragments_count = $this->save_split_data( $key, $this->data );
|
191 |
+
|
192 |
+
$save_data = array(
|
193 |
+
'identifier' => $this->identifier,
|
194 |
+
'done' => 0,
|
195 |
+
'total' => count( $this->data ),
|
196 |
+
'fragments' => $fragments_count,
|
197 |
+
);
|
198 |
+
|
199 |
+
/**
|
200 |
+
* Filters the information that will be saved to the database for this queue type.
|
201 |
+
*
|
202 |
+
* @since 4.7.12
|
203 |
+
*
|
204 |
+
* @param array $save_data
|
205 |
+
* @param self $this
|
206 |
+
*/
|
207 |
+
$save_data = apply_filters( "tribe_process_queue_{$this->identifier}_save_data", $save_data, $this );
|
208 |
+
|
209 |
+
set_transient( $this->get_meta_key( $key ), $save_data );
|
210 |
+
|
211 |
+
$this->did_save = true;
|
212 |
+
$this->id = $key;
|
213 |
+
|
214 |
+
return $this;
|
215 |
+
}
|
216 |
+
|
217 |
+
/**
|
218 |
+
* Generates the unique key for the queue optionally using the client provided
|
219 |
+
* id.
|
220 |
+
*
|
221 |
+
* @since 4.7.12
|
222 |
+
*
|
223 |
+
* @return string
|
224 |
+
*/
|
225 |
+
protected function generate_key( $length = 64 ) {
|
226 |
+
if ( empty( $this->id_base ) ) {
|
227 |
+
$this->id_base = md5( microtime() . mt_rand() );
|
228 |
+
}
|
229 |
+
|
230 |
+
$prepend = $this->identifier . '_batch_';
|
231 |
+
|
232 |
+
$this->batch_key = substr( $prepend . $this->id_base, 0, $length );
|
233 |
+
|
234 |
+
return $this->batch_key;
|
235 |
+
}
|
236 |
+
|
237 |
+
/**
|
238 |
+
* Saves the queue data to the database taking max_packet_size into account.
|
239 |
+
*
|
240 |
+
* In some instances the serialized size of the data might be bigger than the
|
241 |
+
* database `max_packet_size`; trying to write all the data in one query would
|
242 |
+
* make the db "go away...".
|
243 |
+
* Here we try to read the database `max_packet_size` setting and use that information
|
244 |
+
* to avoid overloading the query.
|
245 |
+
*
|
246 |
+
* @param string $key
|
247 |
+
* @param array $data
|
248 |
+
*
|
249 |
+
* @return int The number of fragments the data was split and stored into.
|
250 |
+
*/
|
251 |
+
protected function save_split_data( $key, array $data ) {
|
252 |
+
if ( empty( $data ) ) {
|
253 |
+
return 0;
|
254 |
+
}
|
255 |
+
|
256 |
+
$max_frag_size = $this->get_max_frag_size();
|
257 |
+
// we add a 15% to the size to take the serialization and query overhead into account when fragmenting
|
258 |
+
$serialized_size = ( strlen( utf8_decode( maybe_serialize( $data ) ) ) ) * 1.15;
|
259 |
+
$frags_count = (int) ceil( $serialized_size / $max_frag_size );
|
260 |
+
$per_frag = max( (int) floor( count( $data ) / $frags_count ), 1 );
|
261 |
+
|
262 |
+
$split_data = array_chunk( $data, $per_frag );
|
263 |
+
|
264 |
+
if ( empty( $split_data ) ) {
|
265 |
+
return 0;
|
266 |
+
}
|
267 |
+
|
268 |
+
foreach ( $split_data as $i => $iValue ) {
|
269 |
+
$postfix = 0 === $i ? '' : "_{$i}";
|
270 |
+
update_site_option( $key . $postfix, $split_data[ $i ] );
|
271 |
+
}
|
272 |
+
|
273 |
+
return count( $split_data );
|
274 |
+
}
|
275 |
+
|
276 |
+
/**
|
277 |
+
* Returns the max frag size in bytes.
|
278 |
+
*
|
279 |
+
* The bottleneck here is the database `max_packet_size` so we try to read
|
280 |
+
* it from the database.
|
281 |
+
*
|
282 |
+
* @return int The max size, in bytes, of a data fragment.
|
283 |
+
*/
|
284 |
+
protected function get_max_frag_size() {
|
285 |
+
if ( ! empty( $this->max_frag_size ) ) {
|
286 |
+
return $this->max_frag_size;
|
287 |
+
}
|
288 |
+
|
289 |
+
return tribe( 'db' )->get_max_allowed_packet_size();
|
290 |
+
}
|
291 |
+
|
292 |
+
/**
|
293 |
+
* Sets the maximum size, in bytes, of the queue fragments.
|
294 |
+
*
|
295 |
+
* This will prevent the class from trying to read the value from the database.
|
296 |
+
*
|
297 |
+
* @since 4.7.12
|
298 |
+
*
|
299 |
+
* @param int $max_frag_size
|
300 |
+
*/
|
301 |
+
public function set_max_frag_size( $max_frag_size ) {
|
302 |
+
$this->max_frag_size = $max_frag_size;
|
303 |
+
}
|
304 |
+
|
305 |
+
/**
|
306 |
+
* Returns the queue unique identifier.
|
307 |
+
*
|
308 |
+
* Mind that an id will only be available after saving a queue.
|
309 |
+
*
|
310 |
+
* @since 4.7.12
|
311 |
+
*
|
312 |
+
* @return string
|
313 |
+
* @throws RuntimeException if trying to get the queue id before saving it.
|
314 |
+
*/
|
315 |
+
public function get_id() {
|
316 |
+
if ( null === $this->id ) {
|
317 |
+
// not localized as this is a developer-land error
|
318 |
+
throw new RuntimeException( 'Can only get the id of queue after saving it.' );
|
319 |
+
}
|
320 |
+
|
321 |
+
return $this->id;
|
322 |
+
}
|
323 |
+
|
324 |
+
/**
|
325 |
+
* Overrides the base `dispatch` method to allow for constants and/or environment vars to run
|
326 |
+
* async requests in sync mode.
|
327 |
+
*
|
328 |
+
* @since 4.7.12
|
329 |
+
*
|
330 |
+
* @return mixed
|
331 |
+
*/
|
332 |
+
public function dispatch() {
|
333 |
+
if (
|
334 |
+
( defined( 'TRIBE_NO_ASYNC' ) && true === TRIBE_NO_ASYNC )
|
335 |
+
|| true == getenv( 'TRIBE_NO_ASYNC' )
|
336 |
+
|| (bool) tribe_get_request_var( 'tribe_queue_sync', false )
|
337 |
+
|| tribe_is_truthy( tribe_get_option( 'tribe_queue_sync', false ) )
|
338 |
+
) {
|
339 |
+
return $this->sync_process( $this->data );
|
340 |
+
}
|
341 |
+
|
342 |
+
return parent::dispatch();
|
343 |
+
}
|
344 |
+
|
345 |
+
/**
|
346 |
+
* Handles the process immediately, not in an async manner.
|
347 |
+
*
|
348 |
+
* @since 4.7.12
|
349 |
+
*
|
350 |
+
* @return array An array containing the result of each item handling.
|
351 |
+
*/
|
352 |
+
public function sync_process() {
|
353 |
+
$result = array();
|
354 |
+
$this->doing_sync = true;
|
355 |
+
|
356 |
+
foreach ( $this->data as $item ) {
|
357 |
+
$result[] = $this->task( $item );
|
358 |
+
}
|
359 |
+
|
360 |
+
return $result;
|
361 |
+
}
|
362 |
+
|
363 |
+
/**
|
364 |
+
* {@inheritdoc}
|
365 |
+
*/
|
366 |
+
protected function get_batch() {
|
367 |
+
$batch = parent::get_batch();
|
368 |
+
|
369 |
+
$this->original_batch_count = ! empty( $batch->data ) ? count( $batch->data ) : 0;
|
370 |
+
|
371 |
+
return $batch;
|
372 |
+
}
|
373 |
+
|
374 |
+
/**
|
375 |
+
* {@inheritdoc}
|
376 |
+
*/
|
377 |
+
protected function get_post_args() {
|
378 |
+
$post_args = parent::get_post_args();
|
379 |
+
|
380 |
+
/**
|
381 |
+
* While sending the data into the body makes sense for the async process it does
|
382 |
+
* not make sense when processing a queue since the data will be stored and read
|
383 |
+
* from the database; furthermore this could raise issues with the max POST size.
|
384 |
+
*/
|
385 |
+
$post_args['body'] = array();
|
386 |
+
|
387 |
+
return $post_args;
|
388 |
+
}
|
389 |
+
|
390 |
+
/**
|
391 |
+
* Returns the name of the transient that will store the queue meta information
|
392 |
+
* for the specific key.
|
393 |
+
*
|
394 |
+
* @since 4.7.12
|
395 |
+
*
|
396 |
+
* @param string $key
|
397 |
+
*
|
398 |
+
* @return string
|
399 |
+
*/
|
400 |
+
public function get_meta_key( $key ) {
|
401 |
+
$key = preg_replace( '/^(.*)_\\d+$/', '$1', $key );
|
402 |
+
|
403 |
+
return $key . '_meta';
|
404 |
+
}
|
405 |
+
|
406 |
+
/**
|
407 |
+
* Sets the queue unique id.
|
408 |
+
*
|
409 |
+
* When using this method the client code takes charge of the queue id uniqueness;
|
410 |
+
* the class will not check it.
|
411 |
+
*
|
412 |
+
* @since 4.7.12
|
413 |
+
*
|
414 |
+
* @param string $queue_id
|
415 |
+
*
|
416 |
+
* @throws RuntimeException If trying to set the queue id after saving it.
|
417 |
+
*/
|
418 |
+
public function set_id( $queue_id ) {
|
419 |
+
if ( $this->did_save ) {
|
420 |
+
throw new RuntimeException( 'The queue id can be set only before saving it.' );
|
421 |
+
}
|
422 |
+
|
423 |
+
$queue_id = preg_replace( '/^' . preg_quote( $this->identifier, '/' ) . '_batch_/', '', $queue_id );
|
424 |
+
|
425 |
+
$this->id_base = $queue_id;
|
426 |
+
}
|
427 |
+
|
428 |
+
/**
|
429 |
+
* Returns the name of the option used by the queue to store its batch(es).
|
430 |
+
*
|
431 |
+
* Mind that this value will be set only when first saving the queue and it will not be set
|
432 |
+
* in following queue processing.
|
433 |
+
*
|
434 |
+
* @since 4.7.12
|
435 |
+
*
|
436 |
+
* @param int $n The number of a specific batch option name to get; defaults to `0` to get the
|
437 |
+
* option name of the first one.
|
438 |
+
*
|
439 |
+
* @return string
|
440 |
+
*
|
441 |
+
* @throws RuntimeException If trying to get the value before saving the queue or during following
|
442 |
+
* processing.
|
443 |
+
*/
|
444 |
+
public function get_batch_key( $n = 0 ) {
|
445 |
+
if ( null === $this->batch_key || ! $this->did_save ) {
|
446 |
+
throw new RuntimeException( 'The batch key will only be set after the queue is first saved' );
|
447 |
+
}
|
448 |
+
|
449 |
+
return empty( $n ) ? $this->batch_key : $this->batch_key . '_' . (int) $n;
|
450 |
+
}
|
451 |
+
}
|
common/src/Tribe/Service_Providers/Processes.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class Tribe__Service_Providers__Processes
|
5 |
*
|
6 |
-
* @since
|
7 |
*
|
8 |
* Handles the registration and creation of our async process handlers.
|
9 |
*/
|
@@ -13,30 +13,49 @@ class Tribe__Service_Providers__Processes extends tad_DI52_ServiceProvider {
|
|
13 |
* Binds and sets up implementations.
|
14 |
*/
|
15 |
public function register() {
|
16 |
-
if ( ! (
|
|
|
|
|
|
|
17 |
return;
|
18 |
}
|
19 |
|
20 |
-
|
21 |
-
|
22 |
-
|
|
|
23 |
return;
|
24 |
}
|
25 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
$handlers = array(
|
27 |
'Tribe__Process__Post_Thumbnail_Setter',
|
28 |
);
|
29 |
|
30 |
/**
|
31 |
-
* Filters the process
|
32 |
*
|
33 |
* All handlers should extend the `Tribe__Process__Handler` base class.
|
34 |
*
|
35 |
-
* @since
|
36 |
*
|
37 |
* @param array $handlers
|
38 |
*/
|
39 |
-
$handlers = apply_filters( 'tribe_process_handlers', $handlers );
|
40 |
|
41 |
$all_handlers_actions = array_combine(
|
42 |
$handlers,
|
@@ -49,14 +68,50 @@ class Tribe__Service_Providers__Processes extends tad_DI52_ServiceProvider {
|
|
49 |
return;
|
50 |
}
|
51 |
|
52 |
-
// the
|
53 |
$this->container->make( $handler_class );
|
54 |
}
|
55 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
56 |
/**
|
57 |
* Returns the action for the handler.
|
58 |
*
|
59 |
-
* @since
|
60 |
*
|
61 |
* @param string $handler_class
|
62 |
*
|
@@ -66,4 +121,18 @@ class Tribe__Service_Providers__Processes extends tad_DI52_ServiceProvider {
|
|
66 |
/** @var Tribe__Process__Handler handler_class */
|
67 |
return 'tribe_process_' . call_user_func( array( $handler_class, 'action' ) );
|
68 |
}
|
69 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
/**
|
4 |
* Class Tribe__Service_Providers__Processes
|
5 |
*
|
6 |
+
* @since 4.7.12
|
7 |
*
|
8 |
* Handles the registration and creation of our async process handlers.
|
9 |
*/
|
13 |
* Binds and sets up implementations.
|
14 |
*/
|
15 |
public function register() {
|
16 |
+
if ( ! (
|
17 |
+
tribe( 'context' )->doing_ajax()
|
18 |
+
&& false !== $action = tribe_get_request_var( 'action', false )
|
19 |
+
) ) {
|
20 |
return;
|
21 |
}
|
22 |
|
23 |
+
if (
|
24 |
+
0 !== strpos( $action, 'tribe_process_' )
|
25 |
+
&& 0 !== strpos( $action, 'tribe_queue_' )
|
26 |
+
) {
|
27 |
return;
|
28 |
}
|
29 |
|
30 |
+
if ( 0 === strpos( $action, 'tribe_process_' ) ) {
|
31 |
+
$this->hook_handler_for( $action );
|
32 |
+
} else {
|
33 |
+
$this->hook_queue_for( $action );
|
34 |
+
}
|
35 |
+
}
|
36 |
+
|
37 |
+
/**
|
38 |
+
* Hooks the correct handler for the action.
|
39 |
+
*
|
40 |
+
* @since 4.7.12
|
41 |
+
*
|
42 |
+
* @param string $action
|
43 |
+
*/
|
44 |
+
protected function hook_handler_for( $action ) {
|
45 |
$handlers = array(
|
46 |
'Tribe__Process__Post_Thumbnail_Setter',
|
47 |
);
|
48 |
|
49 |
/**
|
50 |
+
* Filters the process handler classes the Service Provider should handle.
|
51 |
*
|
52 |
* All handlers should extend the `Tribe__Process__Handler` base class.
|
53 |
*
|
54 |
+
* @since 4.7.12
|
55 |
*
|
56 |
* @param array $handlers
|
57 |
*/
|
58 |
+
$handlers = array_unique( apply_filters( 'tribe_process_handlers', $handlers ) );
|
59 |
|
60 |
$all_handlers_actions = array_combine(
|
61 |
$handlers,
|
68 |
return;
|
69 |
}
|
70 |
|
71 |
+
// the handler will handle the hooking
|
72 |
$this->container->make( $handler_class );
|
73 |
}
|
74 |
|
75 |
+
/**
|
76 |
+
* Hooks the correct queue for the action.
|
77 |
+
*
|
78 |
+
* @since 4.7.12
|
79 |
+
*
|
80 |
+
* @param string $action
|
81 |
+
*/
|
82 |
+
protected function hook_queue_for( $action ) {
|
83 |
+
$queues = array();
|
84 |
+
|
85 |
+
/**
|
86 |
+
* Filters the queue processing classes the Service Provider should handle.
|
87 |
+
*
|
88 |
+
* All queues should extend the `Tribe__Process__Queue` base class.
|
89 |
+
*
|
90 |
+
* @since 4.7.12
|
91 |
+
*
|
92 |
+
* @param array $queues
|
93 |
+
*/
|
94 |
+
$queues = array_unique( apply_filters( 'tribe_process_queues', $queues ) );
|
95 |
+
|
96 |
+
$all_queues_actions = array_combine(
|
97 |
+
$queues,
|
98 |
+
array_map( array( $this, 'get_queue_action' ), $queues )
|
99 |
+
);
|
100 |
+
|
101 |
+
$array_search = array_search( $action, $all_queues_actions );
|
102 |
+
|
103 |
+
if ( false === $queue_class = $array_search ) {
|
104 |
+
return;
|
105 |
+
}
|
106 |
+
|
107 |
+
// the queue will handle the hooking
|
108 |
+
$this->container->make( $queue_class );
|
109 |
+
}
|
110 |
+
|
111 |
/**
|
112 |
* Returns the action for the handler.
|
113 |
*
|
114 |
+
* @since 4.7.12
|
115 |
*
|
116 |
* @param string $handler_class
|
117 |
*
|
121 |
/** @var Tribe__Process__Handler handler_class */
|
122 |
return 'tribe_process_' . call_user_func( array( $handler_class, 'action' ) );
|
123 |
}
|
124 |
+
|
125 |
+
/**
|
126 |
+
* Returns the action for the queue.
|
127 |
+
*
|
128 |
+
* @since 4.7.12
|
129 |
+
*
|
130 |
+
* @param string $queue_class
|
131 |
+
*
|
132 |
+
* @return string
|
133 |
+
*/
|
134 |
+
protected function get_queue_action( $queue_class ) {
|
135 |
+
/** @var Tribe__Process__Queue queue_class */
|
136 |
+
return 'tribe_queue_' . call_user_func( array( $queue_class, 'action' ) );
|
137 |
+
}
|
138 |
+
}
|
common/src/Tribe/Timezones.php
CHANGED
@@ -178,28 +178,6 @@ class Tribe__Timezones {
|
|
178 |
return ( 0 === strpos( $timezone, 'UTC' ) && strlen( $timezone ) > 3 );
|
179 |
}
|
180 |
|
181 |
-
/**
|
182 |
-
* Accepts a unix timestamp and adjusts it so that when it is used to constitute
|
183 |
-
* a new datetime string, that string reflects the designated timezone.
|
184 |
-
*
|
185 |
-
* @param string $unix_timestamp
|
186 |
-
* @param string $tzstring
|
187 |
-
*
|
188 |
-
* @return string
|
189 |
-
*/
|
190 |
-
public static function adjust_timestamp( $unix_timestamp, $tzstring ) {
|
191 |
-
try {
|
192 |
-
$local = self::get_timezone( $tzstring );
|
193 |
-
$datetime = date_create_from_format( 'U', $unix_timestamp )->format( Tribe__Date_Utils::DBDATETIMEFORMAT );
|
194 |
-
|
195 |
-
// We prefer format('U') to getTimestamp() here due to our requirement for compatibility with PHP 5.2
|
196 |
-
return date_create_from_format( 'Y-m-d H:i:s', $datetime, $local )->format( 'U' );
|
197 |
-
}
|
198 |
-
catch( Exception $e ) {
|
199 |
-
return $unix_timestamp;
|
200 |
-
}
|
201 |
-
}
|
202 |
-
|
203 |
/**
|
204 |
* Returns a DateTimeZone object matching the representation in $tzstring where
|
205 |
* possible, or else representing UTC (or, in the worst case, false).
|
@@ -296,62 +274,6 @@ class Tribe__Timezones {
|
|
296 |
return $datetime;
|
297 |
}
|
298 |
|
299 |
-
/**
|
300 |
-
* Applies an time offset to the specified date time.
|
301 |
-
*
|
302 |
-
* @param string $datetime The date and time string in a valid date format.
|
303 |
-
* @param int|string $offset (string or numeric offset)
|
304 |
-
* @param bool $invert = false Whether the offset should be added (`true`) or
|
305 |
-
* subtracted (`false`); signum operations carry over so
|
306 |
-
* `-(-23) = +23`.
|
307 |
-
*
|
308 |
-
* @return string
|
309 |
-
*/
|
310 |
-
public static function apply_offset( $datetime, $offset, $invert = false ) {
|
311 |
-
// Normalize
|
312 |
-
$offset = strtolower( trim( $offset ) );
|
313 |
-
|
314 |
-
// Strip any leading "utc" text if set
|
315 |
-
if ( 0 === strpos( $offset, 'utc' ) ) {
|
316 |
-
$offset = substr( $offset, 3 );
|
317 |
-
}
|
318 |
-
|
319 |
-
// It's possible no adjustment will be needed
|
320 |
-
if ( 0 === (int) $offset ) {
|
321 |
-
return $datetime;
|
322 |
-
}
|
323 |
-
|
324 |
-
// if the offset contains fractions like :15, :30 or :45 convert them
|
325 |
-
$supported_offsets = array(
|
326 |
-
'/:15$/' => '.25',
|
327 |
-
'/:30$/' => '.5',
|
328 |
-
'/:45$/' => '.75',
|
329 |
-
);
|
330 |
-
$offset = preg_replace( array_keys( $supported_offsets ), array_values( $supported_offsets ), $offset );
|
331 |
-
|
332 |
-
// Convert the offset to minutes for easier handling of fractional offsets
|
333 |
-
$offset = (int) ( $offset * 60 );
|
334 |
-
|
335 |
-
// Invert the offset? Useful for stripping an offset that has already been applied
|
336 |
-
if ( $invert ) {
|
337 |
-
$offset *= - 1;
|
338 |
-
}
|
339 |
-
|
340 |
-
if ( $offset > 0 ) {
|
341 |
-
$offset = '+' . $offset;
|
342 |
-
}
|
343 |
-
|
344 |
-
$offset = $offset . ' minutes';
|
345 |
-
|
346 |
-
$offset_datetime = date_create( $datetime );
|
347 |
-
|
348 |
-
if ( $offset_datetime && $offset_datetime->modify( $offset ) ) {
|
349 |
-
return $offset_datetime->format( Tribe__Date_Utils::DBDATETIMEFORMAT );
|
350 |
-
}
|
351 |
-
|
352 |
-
return $datetime;
|
353 |
-
}
|
354 |
-
|
355 |
/**
|
356 |
* Tries to convert the provided $datetime to the timezone represented by $tzstring.
|
357 |
*
|
@@ -364,7 +286,9 @@ class Tribe__Timezones {
|
|
364 |
* @return string
|
365 |
*/
|
366 |
public static function to_tz( $datetime, $tzstring ) {
|
|
|
367 |
if ( self::is_utc_offset( $tzstring ) ) {
|
|
|
368 |
return self::apply_offset( $datetime, $tzstring );
|
369 |
}
|
370 |
|
@@ -381,48 +305,6 @@ class Tribe__Timezones {
|
|
381 |
return $datetime;
|
382 |
}
|
383 |
|
384 |
-
/**
|
385 |
-
* Try to figure out the Timezone name base on offset
|
386 |
-
*
|
387 |
-
* @since 4.0.7
|
388 |
-
*
|
389 |
-
* @param string|int|float $timezone The timezone
|
390 |
-
*
|
391 |
-
* @return string The Guessed Timezone String
|
392 |
-
*/
|
393 |
-
public static function maybe_get_tz_name( $timezone ) {
|
394 |
-
if ( ! Tribe__Timezones::is_utc_offset( $timezone ) && ! is_numeric( $timezone ) ) {
|
395 |
-
return $timezone;
|
396 |
-
}
|
397 |
-
|
398 |
-
if ( ! is_numeric( $timezone ) ) {
|
399 |
-
$offset = str_replace( 'utc', '', trim( strtolower( $timezone ) ) );
|
400 |
-
} else {
|
401 |
-
$offset = $timezone;
|
402 |
-
}
|
403 |
-
|
404 |
-
|
405 |
-
// try to get timezone from gmt_offset, respecting daylight savings
|
406 |
-
$timezone = timezone_name_from_abbr( null, $offset * 3600, true );
|
407 |
-
|
408 |
-
// if that didn't work, maybe they don't have daylight savings
|
409 |
-
if ( false === $timezone ) {
|
410 |
-
$timezone = timezone_name_from_abbr( null, $offset * 3600, false );
|
411 |
-
}
|
412 |
-
|
413 |
-
// and if THAT didn't work, round the gmt_offset down and then try to get the timezone respecting daylight savings
|
414 |
-
if ( false === $timezone ) {
|
415 |
-
$timezone = timezone_name_from_abbr( null, (int) $offset * 3600, true );
|
416 |
-
}
|
417 |
-
|
418 |
-
// lastly if that didn't work, round the gmt_offset down and maybe that TZ doesn't do daylight savings
|
419 |
-
if ( false === $timezone ) {
|
420 |
-
$timezone = timezone_name_from_abbr( null, (int) $offset * 3600, false );
|
421 |
-
}
|
422 |
-
|
423 |
-
return $timezone;
|
424 |
-
}
|
425 |
-
|
426 |
/**
|
427 |
* Localizes a date or timestamp using WordPress timezone and returns it in the specified format.
|
428 |
*
|
@@ -438,9 +320,11 @@ class Tribe__Timezones {
|
|
438 |
*/
|
439 |
public static function localize_date( $format = null, $date = null, $timezone = null ) {
|
440 |
if ( empty( $timezone ) ) {
|
441 |
-
$timezone = self::
|
442 |
}
|
443 |
|
|
|
|
|
444 |
try {
|
445 |
$timezone_object = new DateTimeZone( $timezone );
|
446 |
|
@@ -507,6 +391,8 @@ class Tribe__Timezones {
|
|
507 |
* If this is not possible or if $utc_offset_string does not match the expected pattern,
|
508 |
* boolean false is returned.
|
509 |
*
|
|
|
|
|
510 |
* @since 4.6.3
|
511 |
*
|
512 |
* @param string $utc_offset_string
|
@@ -540,5 +426,134 @@ class Tribe__Timezones {
|
|
540 |
return false;
|
541 |
}
|
542 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
543 |
}
|
544 |
|
178 |
return ( 0 === strpos( $timezone, 'UTC' ) && strlen( $timezone ) > 3 );
|
179 |
}
|
180 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
181 |
/**
|
182 |
* Returns a DateTimeZone object matching the representation in $tzstring where
|
183 |
* possible, or else representing UTC (or, in the worst case, false).
|
274 |
return $datetime;
|
275 |
}
|
276 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
277 |
/**
|
278 |
* Tries to convert the provided $datetime to the timezone represented by $tzstring.
|
279 |
*
|
286 |
* @return string
|
287 |
*/
|
288 |
public static function to_tz( $datetime, $tzstring ) {
|
289 |
+
|
290 |
if ( self::is_utc_offset( $tzstring ) ) {
|
291 |
+
|
292 |
return self::apply_offset( $datetime, $tzstring );
|
293 |
}
|
294 |
|
305 |
return $datetime;
|
306 |
}
|
307 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
308 |
/**
|
309 |
* Localizes a date or timestamp using WordPress timezone and returns it in the specified format.
|
310 |
*
|
320 |
*/
|
321 |
public static function localize_date( $format = null, $date = null, $timezone = null ) {
|
322 |
if ( empty( $timezone ) ) {
|
323 |
+
$timezone = self::wp_timezone_string();
|
324 |
}
|
325 |
|
326 |
+
$timezone = self::generate_timezone_string_from_utc_offset( $timezone );
|
327 |
+
|
328 |
try {
|
329 |
$timezone_object = new DateTimeZone( $timezone );
|
330 |
|
391 |
* If this is not possible or if $utc_offset_string does not match the expected pattern,
|
392 |
* boolean false is returned.
|
393 |
*
|
394 |
+
* @todo revise to eliminate all of these: maybe_get_tz_name, apply_offset, timezone_from_utc_offset, and adjust_timestamp
|
395 |
+
*
|
396 |
* @since 4.6.3
|
397 |
*
|
398 |
* @param string $utc_offset_string
|
426 |
return false;
|
427 |
}
|
428 |
}
|
429 |
+
|
430 |
+
/**
|
431 |
+
* Applies an time offset to the specified date time.
|
432 |
+
*
|
433 |
+
* @todo revise to eliminate all of these: maybe_get_tz_name, apply_offset, timezone_from_utc_offset, and adjust_timestamp
|
434 |
+
*
|
435 |
+
* @param string $datetime The date and time string in a valid date format.
|
436 |
+
* @param int|string $offset (string or numeric offset)
|
437 |
+
* @param bool $invert = false Whether the offset should be added (`true`) or
|
438 |
+
* subtracted (`false`); signum operations carry over so
|
439 |
+
* `-(-23) = +23`.
|
440 |
+
*
|
441 |
+
* @return string
|
442 |
+
*/
|
443 |
+
public static function apply_offset( $datetime, $offset, $invert = false ) {
|
444 |
+
// Normalize
|
445 |
+
$offset = strtolower( trim( $offset ) );
|
446 |
+
|
447 |
+
// Strip any leading "utc" text if set
|
448 |
+
if ( 0 === strpos( $offset, 'utc' ) ) {
|
449 |
+
$offset = substr( $offset, 3 );
|
450 |
+
}
|
451 |
+
|
452 |
+
// It's possible no adjustment will be needed
|
453 |
+
if ( 0 === (int) $offset ) {
|
454 |
+
return $datetime;
|
455 |
+
}
|
456 |
+
|
457 |
+
// if the offset contains fractions like :15, :30 or :45 convert them
|
458 |
+
$supported_offsets = array(
|
459 |
+
'/:15$/' => '.25',
|
460 |
+
'/:30$/' => '.5',
|
461 |
+
'/:45$/' => '.75',
|
462 |
+
);
|
463 |
+
$offset = preg_replace( array_keys( $supported_offsets ), array_values( $supported_offsets ), $offset );
|
464 |
+
|
465 |
+
// Convert the offset to minutes for easier handling of fractional offsets
|
466 |
+
$offset = (int) ( $offset * 60 );
|
467 |
+
|
468 |
+
// Invert the offset? Useful for stripping an offset that has already been applied
|
469 |
+
if ( $invert ) {
|
470 |
+
$offset *= - 1;
|
471 |
+
}
|
472 |
+
|
473 |
+
if ( $offset > 0 ) {
|
474 |
+
$offset = '+' . $offset;
|
475 |
+
}
|
476 |
+
|
477 |
+
$offset = $offset . ' minutes';
|
478 |
+
|
479 |
+
$offset_datetime = date_create( $datetime );
|
480 |
+
|
481 |
+
if ( $offset_datetime && $offset_datetime->modify( $offset ) ) {
|
482 |
+
return $offset_datetime->format( Tribe__Date_Utils::DBDATETIMEFORMAT );
|
483 |
+
}
|
484 |
+
|
485 |
+
return $datetime;
|
486 |
+
}
|
487 |
+
|
488 |
+
/**
|
489 |
+
* Try to figure out the Timezone name base on offset
|
490 |
+
*
|
491 |
+
* @since 4.0.7
|
492 |
+
*
|
493 |
+
* @todo revise to eliminate all of these: maybe_get_tz_name, apply_offset, timezone_from_utc_offset, and adjust_timestamp
|
494 |
+
*
|
495 |
+
* @param string|int|float $timezone The timezone
|
496 |
+
*
|
497 |
+
* @return string The Guessed Timezone String
|
498 |
+
*/
|
499 |
+
public static function maybe_get_tz_name( $timezone ) {
|
500 |
+
if ( ! self::is_utc_offset( $timezone ) && ! is_numeric( $timezone ) ) {
|
501 |
+
return $timezone;
|
502 |
+
}
|
503 |
+
|
504 |
+
if ( ! is_numeric( $timezone ) ) {
|
505 |
+
$offset = str_replace( 'utc', '', trim( strtolower( $timezone ) ) );
|
506 |
+
} else {
|
507 |
+
$offset = $timezone;
|
508 |
+
}
|
509 |
+
|
510 |
+
|
511 |
+
// try to get timezone from gmt_offset, respecting daylight savings
|
512 |
+
$timezone = timezone_name_from_abbr( null, $offset * 3600, true );
|
513 |
+
|
514 |
+
// if that didn't work, maybe they don't have daylight savings
|
515 |
+
if ( false === $timezone ) {
|
516 |
+
$timezone = timezone_name_from_abbr( null, $offset * 3600, false );
|
517 |
+
}
|
518 |
+
|
519 |
+
// and if THAT didn't work, round the gmt_offset down and then try to get the timezone respecting daylight savings
|
520 |
+
if ( false === $timezone ) {
|
521 |
+
$timezone = timezone_name_from_abbr( null, (int) $offset * 3600, true );
|
522 |
+
}
|
523 |
+
|
524 |
+
// lastly if that didn't work, round the gmt_offset down and maybe that TZ doesn't do daylight savings
|
525 |
+
if ( false === $timezone ) {
|
526 |
+
$timezone = timezone_name_from_abbr( null, (int) $offset * 3600, false );
|
527 |
+
}
|
528 |
+
|
529 |
+
return $timezone;
|
530 |
+
}
|
531 |
+
|
532 |
+
/**
|
533 |
+
* Accepts a unix timestamp and adjusts it so that when it is used to constitute
|
534 |
+
* a new datetime string, that string reflects the designated timezone.
|
535 |
+
*
|
536 |
+
* @todo revise to eliminate all of these: maybe_get_tz_name, apply_offset, timezone_from_utc_offset, and adjust_timestamp
|
537 |
+
*
|
538 |
+
* @deprecated 4.7.12
|
539 |
+
*
|
540 |
+
* @param string $unix_timestamp
|
541 |
+
* @param string $tzstring
|
542 |
+
*
|
543 |
+
* @return string
|
544 |
+
*/
|
545 |
+
public static function adjust_timestamp( $unix_timestamp, $tzstring ) {
|
546 |
+
try {
|
547 |
+
$local = self::get_timezone( $tzstring );
|
548 |
+
|
549 |
+
$datetime = date_create_from_format( 'U', $unix_timestamp )->format( Tribe__Date_Utils::DBDATETIMEFORMAT );
|
550 |
+
|
551 |
+
// We prefer format('U') to getTimestamp() here due to our requirement for compatibility with PHP 5.2
|
552 |
+
return date_create_from_format( 'Y-m-d H:i:s', $datetime, $local )->format( 'U' );
|
553 |
+
}
|
554 |
+
catch( Exception $e ) {
|
555 |
+
return $unix_timestamp;
|
556 |
+
}
|
557 |
+
}
|
558 |
}
|
559 |
|
common/src/admin-views/tribe-options-help.php
CHANGED
@@ -30,16 +30,16 @@ $help->add_section_content( 'extra-help', array(
|
|
30 |
|
31 |
sprintf( __( '%s. All of the common (and not-so-common) answers to questions we see are here. It’s often the fastest path to finding an answer!', 'tribe-common' ), '<strong><a href="http://m.tri.be/18j9" target="_blank">' . __( 'Check our Knowledgebase', 'tribe-common' ) . '</a></strong>' ),
|
32 |
sprintf( __( '%s. Testing for an existing conflict is the best start for in-depth troubleshooting. We will often ask you to follow these steps when opening a new thread, so doing this ahead of time will be super helpful.', 'tribe-common' ), '<strong><a href="http://m.tri.be/18jh" target="_blank">' . __( 'Test for a theme or plugin conflict', 'tribe-common' ) . '</a></strong>' ),
|
33 |
-
sprintf( __( '%s. There are very few issues we haven’t seen and it’s likely another user has already asked your question and gotten an answer from our support staff. While posting to the
|
34 |
), 10 );
|
35 |
|
36 |
// By default these three will be gathered
|
37 |
-
$help->add_section_content( 'extra-help', __( 'Please note that all hands-on support is provided via the
|
38 |
$help->add_section_content( 'extra-help', '<div style="text-align: right;"><a href="http://m.tri.be/18ji" target="_blank" class="button">' . __( 'Read more about our support policy', 'tribe-common' ) . '</a></div>', 40 );
|
39 |
|
40 |
// Creates the System Info section
|
41 |
$help->add_section( 'system-info', __( 'System Information', 'tribe-common' ), 30 );
|
42 |
-
$help->add_section_content( 'system-info', __( 'The details of your calendar plugin and settings is often needed for you or our staff to help troubleshoot an issue. Please opt-in below to automatically share your system information with our support team. This will allow us to assist you faster if you post in our
|
43 |
|
44 |
$help->add_section_content(
|
45 |
'system-info',
|
30 |
|
31 |
sprintf( __( '%s. All of the common (and not-so-common) answers to questions we see are here. It’s often the fastest path to finding an answer!', 'tribe-common' ), '<strong><a href="http://m.tri.be/18j9" target="_blank">' . __( 'Check our Knowledgebase', 'tribe-common' ) . '</a></strong>' ),
|
32 |
sprintf( __( '%s. Testing for an existing conflict is the best start for in-depth troubleshooting. We will often ask you to follow these steps when opening a new thread, so doing this ahead of time will be super helpful.', 'tribe-common' ), '<strong><a href="http://m.tri.be/18jh" target="_blank">' . __( 'Test for a theme or plugin conflict', 'tribe-common' ) . '</a></strong>' ),
|
33 |
+
sprintf( __( '%s. There are very few issues we haven’t seen and it’s likely another user has already asked your question and gotten an answer from our support staff. While posting to the help desk is open only to paid customers, they are open for anyone to search and review.', 'tribe-common' ), '<strong><a href="http://m.tri.be/4w/" target="_blank">' . __( 'Search our support help desk', 'tribe-common' ) . '</a></strong>' ),
|
34 |
), 10 );
|
35 |
|
36 |
// By default these three will be gathered
|
37 |
+
$help->add_section_content( 'extra-help', __( 'Please note that all hands-on support is provided via the help desk. You can email or tweet at us… but we will probably point you back to the help desk 😄', 'tribe-common' ), 40 );
|
38 |
$help->add_section_content( 'extra-help', '<div style="text-align: right;"><a href="http://m.tri.be/18ji" target="_blank" class="button">' . __( 'Read more about our support policy', 'tribe-common' ) . '</a></div>', 40 );
|
39 |
|
40 |
// Creates the System Info section
|
41 |
$help->add_section( 'system-info', __( 'System Information', 'tribe-common' ), 30 );
|
42 |
+
$help->add_section_content( 'system-info', __( 'The details of your calendar plugin and settings is often needed for you or our staff to help troubleshoot an issue. Please opt-in below to automatically share your system information with our support team. This will allow us to assist you faster if you post in our help desk.', 'tribe-common' ), 0 );
|
43 |
|
44 |
$help->add_section_content(
|
45 |
'system-info',
|
common/src/functions/template-tags/date.php
CHANGED
@@ -296,7 +296,7 @@ if ( ! function_exists( 'tribe_get_start_date' ) ) {
|
|
296 |
|
297 |
// @todo move timezones to Common
|
298 |
if ( class_exists( 'Tribe__Events__Timezones' ) ) {
|
299 |
-
$start_date = Tribe__Events__Timezones::event_start_timestamp( $event->ID );
|
300 |
} else {
|
301 |
return null;
|
302 |
}
|
296 |
|
297 |
// @todo move timezones to Common
|
298 |
if ( class_exists( 'Tribe__Events__Timezones' ) ) {
|
299 |
+
$start_date = Tribe__Events__Timezones::event_start_timestamp( $event->ID, $timezone );
|
300 |
} else {
|
301 |
return null;
|
302 |
}
|
common/src/resources/css/datatables.css
CHANGED
@@ -37,19 +37,19 @@ table.dataTable thead .sorting,
|
|
37 |
background-repeat: no-repeat;
|
38 |
}
|
39 |
table.dataTable thead .sorting {
|
40 |
-
background-image: url("../../../vendor/datatables/
|
41 |
}
|
42 |
table.dataTable thead .sorting_asc {
|
43 |
-
background-image: url("../../../vendor/datatables/
|
44 |
}
|
45 |
table.dataTable thead .sorting_desc {
|
46 |
-
background-image: url("../../../vendor/datatables/
|
47 |
}
|
48 |
table.dataTable thead .sorting_asc_disabled {
|
49 |
-
background-image: url("../../../vendor/datatables/
|
50 |
}
|
51 |
table.dataTable thead .sorting_desc_disabled {
|
52 |
-
background-image: url("../../../vendor/datatables/
|
53 |
}
|
54 |
table.dataTable.widefat thead th input, table.dataTable.widefat thead td input, table.dataTable.widefat tfoot th input, table.dataTable.widefat tfoot td input {
|
55 |
margin: 0 0 0 8px;
|
37 |
background-repeat: no-repeat;
|
38 |
}
|
39 |
table.dataTable thead .sorting {
|
40 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_both.png");
|
41 |
}
|
42 |
table.dataTable thead .sorting_asc {
|
43 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_asc.png");
|
44 |
}
|
45 |
table.dataTable thead .sorting_desc {
|
46 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_desc.png");
|
47 |
}
|
48 |
table.dataTable thead .sorting_asc_disabled {
|
49 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_asc_disabled.png");
|
50 |
}
|
51 |
table.dataTable thead .sorting_desc_disabled {
|
52 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_desc_disabled.png");
|
53 |
}
|
54 |
table.dataTable.widefat thead th input, table.dataTable.widefat thead td input, table.dataTable.widefat tfoot th input, table.dataTable.widefat tfoot td input {
|
55 |
margin: 0 0 0 8px;
|
common/src/resources/css/datatables.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
table.dataTable{border-collapse:separate;border-spacing:0;clear:both;margin:0 auto;width:100%}table.dataTable thead td:active,table.dataTable thead th:active{outline:none}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_desc{cursor:pointer;cursor:hand}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_asc_disabled,table.dataTable thead .sorting_desc,table.dataTable thead .sorting_desc_disabled{background-position:100%;background-repeat:no-repeat}table.dataTable thead .sorting{background-image:url(../../../vendor/datatables/media/images/sort_both.png)}table.dataTable thead .sorting_asc{background-image:url(../../../vendor/datatables/media/images/sort_asc.png)}table.dataTable thead .sorting_desc{background-image:url(../../../vendor/datatables/media/images/sort_desc.png)}table.dataTable thead .sorting_asc_disabled{background-image:url(../../../vendor/datatables/media/images/sort_asc_disabled.png)}table.dataTable thead .sorting_desc_disabled{background-image:url(../../../vendor/datatables/media/images/sort_desc_disabled.png)}table.dataTable.widefat tfoot td input,table.dataTable.widefat tfoot th input,table.dataTable.widefat thead td input,table.dataTable.widefat thead th input{margin:0 0 0 8px;vertical-align:text-top}table.dataTable.widefat tfoot td.check-column,table.dataTable.widefat thead td.check-column{padding-top:4px;vertical-align:middle}table.dataTable.widefat tbody th.check-column,table.dataTable.widefat tfoot th.check-column,table.dataTable.widefat thead th.check-column{padding:11px 0 0 3px}table.dataTable .check-column{width:2.2em}table.dataTable.display tbody td,table.dataTable.display tbody th,table.dataTable.row-border tbody td,table.dataTable.row-border tbody th{border-top:1px solid #ddd}table.dataTable.display tbody tr:first-child td,table.dataTable.display tbody tr:first-child th,table.dataTable.row-border tbody tr:first-child td,table.dataTable.row-border tbody tr:first-child th{border-top:none}table.dataTable.cell-border tbody td,table.dataTable.cell-border tbody th{border-top:1px solid #ddd;border-right:1px solid #ddd}table.dataTable.cell-border tbody tr td:first-child,table.dataTable.cell-border tbody tr th:first-child{border-left:1px solid #ddd}table.dataTable.cell-border tbody tr:first-child td,table.dataTable.cell-border tbody tr:first-child th{border-top:none}table.dataTable.display tbody tr.odd,table.dataTable.stripe tbody tr.odd{background-color:#f9f9f9}table.dataTable.display tbody tr:hover,table.dataTable.hover tbody tr:hover{background-color:#f6f6f6}table.dataTable.display tbody tr>.sorting_1,table.dataTable.display tbody tr>.sorting_2,table.dataTable.display tbody tr>.sorting_3,table.dataTable.order-column tbody tr>.sorting_1,table.dataTable.order-column tbody tr>.sorting_2,table.dataTable.order-column tbody tr>.sorting_3{background-color:#fafafa}table.dataTable.display tbody tr.odd>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd>.sorting_1{background-color:#f1f1f1}table.dataTable.display tbody tr.odd>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd>.sorting_2{background-color:#f3f3f3}table.dataTable.display tbody tr.odd>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd>.sorting_3{background-color:#f5f5f5}table.dataTable.display tbody tr.even>.sorting_1,table.dataTable.order-column.stripe tbody tr.even>.sorting_1{background-color:#fafafa}table.dataTable.display tbody tr.even>.sorting_2,table.dataTable.order-column.stripe tbody tr.even>.sorting_2{background-color:#fcfcfc}table.dataTable.display tbody tr.even>.sorting_3,table.dataTable.order-column.stripe tbody tr.even>.sorting_3{background-color:#fefefe}table.dataTable.display tbody tr:hover>.sorting_1,table.dataTable.order-column.hover tbody tr:hover>.sorting_1{background-color:#eaeaea}table.dataTable.display tbody tr:hover>.sorting_2,table.dataTable.order-column.hover tbody tr:hover>.sorting_2{background-color:#ececec}table.dataTable.display tbody tr:hover>.sorting_3,table.dataTable.order-column.hover tbody tr:hover>.sorting_3{background-color:#efefef}table.dataTable.no-footer{border-bottom:1px solid #111}table.dataTable.nowrap td,table.dataTable.nowrap th{white-space:nowrap}table.dataTable.compact thead td,table.dataTable.compact thead th{padding:4px 17px 4px 4px}table.dataTable.compact tbody td,table.dataTable.compact tbody th,table.dataTable.compact tfoot td,table.dataTable.compact tfoot th{padding:4px}table.dataTable td.dt-left,table.dataTable th.dt-left{text-align:left}table.dataTable td.dataTables_empty,table.dataTable td.dt-center,table.dataTable th.dt-center{text-align:center}table.dataTable td.dt-right,table.dataTable th.dt-right{text-align:right}table.dataTable td.dt-justify,table.dataTable th.dt-justify{text-align:justify}table.dataTable td.dt-nowrap,table.dataTable th.dt-nowrap{white-space:nowrap}table.dataTable tfoot td.dt-head-left,table.dataTable tfoot th.dt-head-left,table.dataTable thead td.dt-head-left,table.dataTable thead th.dt-head-left{text-align:left}table.dataTable tfoot td.dt-head-center,table.dataTable tfoot th.dt-head-center,table.dataTable thead td.dt-head-center,table.dataTable thead th.dt-head-center{text-align:center}table.dataTable tfoot td.dt-head-right,table.dataTable tfoot th.dt-head-right,table.dataTable thead td.dt-head-right,table.dataTable thead th.dt-head-right{text-align:right}table.dataTable tfoot td.dt-head-justify,table.dataTable tfoot th.dt-head-justify,table.dataTable thead td.dt-head-justify,table.dataTable thead th.dt-head-justify{text-align:justify}table.dataTable tfoot td.dt-head-nowrap,table.dataTable tfoot th.dt-head-nowrap,table.dataTable thead td.dt-head-nowrap,table.dataTable thead th.dt-head-nowrap{white-space:nowrap}table.dataTable tbody td.dt-body-left,table.dataTable tbody th.dt-body-left{text-align:left}table.dataTable tbody td.dt-body-center,table.dataTable tbody th.dt-body-center{text-align:center}table.dataTable tbody td.dt-body-right,table.dataTable tbody th.dt-body-right{text-align:right}table.dataTable tbody td.dt-body-justify,table.dataTable tbody th.dt-body-justify{text-align:justify}table.dataTable tbody td.dt-body-nowrap,table.dataTable tbody th.dt-body-nowrap{white-space:nowrap}table.dataTable,table.dataTable td,table.dataTable th{box-sizing:content-box}.dataTables_wrapper{clear:both;position:relative;zoom:1}.dataTables_wrapper .dataTables_length{float:left}.dataTables_wrapper .dataTables_filter{float:right;text-align:right}.dataTables_wrapper .dataTables_filter input{margin-left:.5em}.dataTables_wrapper .dataTables_info{clear:both;float:left;padding-top:.755em}.dataTables_wrapper .dataTables_paginate{float:right;padding-top:.25em;text-align:right}.dataTables_wrapper .dataTables_paginate .paginate_button{border:1px solid transparent;border-radius:3px;box-shadow:none;box-sizing:border-box;color:#555;cursor:pointer;display:inline-block;font-size:13px;height:28px;line-height:26px;margin:0 0 0 2px;padding:0 10px 1px;text-decoration:none;vertical-align:top;white-space:nowrap}.dataTables_wrapper .dataTables_paginate .paginate_button:active,.dataTables_wrapper .dataTables_paginate .paginate_button:hover{background:#fafafa;border-color:#999;color:#23282d}.dataTables_wrapper .dataTables_paginate .paginate_button.next,.dataTables_wrapper .dataTables_paginate .paginate_button.previous{background:transparent;border-color:transparent;box-shadow:none;color:#23282d}.dataTables_wrapper .dataTables_paginate .paginate_button.next.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.previous.disabled{background:transparent;border-color:transparent;box-shadow:none}.dataTables_wrapper .dataTables_paginate .paginate_button.next.disabled:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.previous.disabled:hover{background:transparent;border-color:transparent;box-shadow:none;text-decoration:none}.dataTables_wrapper .dataTables_paginate .paginate_button.next:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.previous:hover{color:#222;text-decoration:underline}.dataTables_wrapper .dataTables_paginate .paginate_button.current,.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover{background:#fcfcfc;border-color:#999;box-shadow:0 1px 0 #ccc;color:#23282d;text-decoration:none}.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover{background:#f7f7f7;border-color:#ddd;box-shadow:none;color:#a0a5aa;cursor:default;text-shadow:0 1px 0 #fff;transform:none}.dataTables_wrapper .dataTables_paginate .ellipsis{padding:0 1em}.dataTables_wrapper .dataTables_processing{position:absolute;top:50%;left:50%;width:100%;height:40px;margin-left:-50%;margin-top:-25px;padding-top:20px;text-align:center;font-size:1.2em;background-color:#fff;background:linear-gradient(90deg,hsla(0,0%,100%,0) 0,hsla(0,0%,100%,.9) 25%,hsla(0,0%,100%,.9) 75%,hsla(0,0%,100%,0))}.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_paginate,.dataTables_wrapper .dataTables_processing{color:#333}.dataTables_wrapper .dataTables_scroll{clear:both}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody{margin-top:-1px;-webkit-overflow-scrolling:touch}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th{vertical-align:middle}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th>div.dataTables_sizing,.dataTables_wrapper .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td>div.dataTables_sizing{height:0;overflow:hidden;margin:0!important;padding:0!important}.dataTables_wrapper.no-footer .dataTables_scrollBody{border-bottom:1px solid #111}.dataTables_wrapper.no-footer div.dataTables_scrollBody table,.dataTables_wrapper.no-footer div.dataTables_scrollHead table{border-bottom:none}.dataTables_wrapper:after{visibility:hidden;display:block;content:"";clear:both;height:0}@media screen and (max-width:767px){.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_paginate{float:none;text-align:center}.dataTables_wrapper .dataTables_paginate{margin-top:.5em}}@media screen and (max-width:640px){.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_length{float:none;text-align:center}.dataTables_wrapper .dataTables_filter{margin-top:.5em}}
|
1 |
+
table.dataTable{border-collapse:separate;border-spacing:0;clear:both;margin:0 auto;width:100%}table.dataTable thead td:active,table.dataTable thead th:active{outline:none}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_desc{cursor:pointer;cursor:hand}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_asc_disabled,table.dataTable thead .sorting_desc,table.dataTable thead .sorting_desc_disabled{background-position:100%;background-repeat:no-repeat}table.dataTable thead .sorting{background-image:url(../../../vendor/datatables/DataTables/images/sort_both.png)}table.dataTable thead .sorting_asc{background-image:url(../../../vendor/datatables/DataTables/images/sort_asc.png)}table.dataTable thead .sorting_desc{background-image:url(../../../vendor/datatables/DataTables/images/sort_desc.png)}table.dataTable thead .sorting_asc_disabled{background-image:url(../../../vendor/datatables/DataTables/images/sort_asc_disabled.png)}table.dataTable thead .sorting_desc_disabled{background-image:url(../../../vendor/datatables/DataTables/images/sort_desc_disabled.png)}table.dataTable.widefat tfoot td input,table.dataTable.widefat tfoot th input,table.dataTable.widefat thead td input,table.dataTable.widefat thead th input{margin:0 0 0 8px;vertical-align:text-top}table.dataTable.widefat tfoot td.check-column,table.dataTable.widefat thead td.check-column{padding-top:4px;vertical-align:middle}table.dataTable.widefat tbody th.check-column,table.dataTable.widefat tfoot th.check-column,table.dataTable.widefat thead th.check-column{padding:11px 0 0 3px}table.dataTable .check-column{width:2.2em}table.dataTable.display tbody td,table.dataTable.display tbody th,table.dataTable.row-border tbody td,table.dataTable.row-border tbody th{border-top:1px solid #ddd}table.dataTable.display tbody tr:first-child td,table.dataTable.display tbody tr:first-child th,table.dataTable.row-border tbody tr:first-child td,table.dataTable.row-border tbody tr:first-child th{border-top:none}table.dataTable.cell-border tbody td,table.dataTable.cell-border tbody th{border-top:1px solid #ddd;border-right:1px solid #ddd}table.dataTable.cell-border tbody tr td:first-child,table.dataTable.cell-border tbody tr th:first-child{border-left:1px solid #ddd}table.dataTable.cell-border tbody tr:first-child td,table.dataTable.cell-border tbody tr:first-child th{border-top:none}table.dataTable.display tbody tr.odd,table.dataTable.stripe tbody tr.odd{background-color:#f9f9f9}table.dataTable.display tbody tr:hover,table.dataTable.hover tbody tr:hover{background-color:#f6f6f6}table.dataTable.display tbody tr>.sorting_1,table.dataTable.display tbody tr>.sorting_2,table.dataTable.display tbody tr>.sorting_3,table.dataTable.order-column tbody tr>.sorting_1,table.dataTable.order-column tbody tr>.sorting_2,table.dataTable.order-column tbody tr>.sorting_3{background-color:#fafafa}table.dataTable.display tbody tr.odd>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd>.sorting_1{background-color:#f1f1f1}table.dataTable.display tbody tr.odd>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd>.sorting_2{background-color:#f3f3f3}table.dataTable.display tbody tr.odd>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd>.sorting_3{background-color:#f5f5f5}table.dataTable.display tbody tr.even>.sorting_1,table.dataTable.order-column.stripe tbody tr.even>.sorting_1{background-color:#fafafa}table.dataTable.display tbody tr.even>.sorting_2,table.dataTable.order-column.stripe tbody tr.even>.sorting_2{background-color:#fcfcfc}table.dataTable.display tbody tr.even>.sorting_3,table.dataTable.order-column.stripe tbody tr.even>.sorting_3{background-color:#fefefe}table.dataTable.display tbody tr:hover>.sorting_1,table.dataTable.order-column.hover tbody tr:hover>.sorting_1{background-color:#eaeaea}table.dataTable.display tbody tr:hover>.sorting_2,table.dataTable.order-column.hover tbody tr:hover>.sorting_2{background-color:#ececec}table.dataTable.display tbody tr:hover>.sorting_3,table.dataTable.order-column.hover tbody tr:hover>.sorting_3{background-color:#efefef}table.dataTable.no-footer{border-bottom:1px solid #111}table.dataTable.nowrap td,table.dataTable.nowrap th{white-space:nowrap}table.dataTable.compact thead td,table.dataTable.compact thead th{padding:4px 17px 4px 4px}table.dataTable.compact tbody td,table.dataTable.compact tbody th,table.dataTable.compact tfoot td,table.dataTable.compact tfoot th{padding:4px}table.dataTable td.dt-left,table.dataTable th.dt-left{text-align:left}table.dataTable td.dataTables_empty,table.dataTable td.dt-center,table.dataTable th.dt-center{text-align:center}table.dataTable td.dt-right,table.dataTable th.dt-right{text-align:right}table.dataTable td.dt-justify,table.dataTable th.dt-justify{text-align:justify}table.dataTable td.dt-nowrap,table.dataTable th.dt-nowrap{white-space:nowrap}table.dataTable tfoot td.dt-head-left,table.dataTable tfoot th.dt-head-left,table.dataTable thead td.dt-head-left,table.dataTable thead th.dt-head-left{text-align:left}table.dataTable tfoot td.dt-head-center,table.dataTable tfoot th.dt-head-center,table.dataTable thead td.dt-head-center,table.dataTable thead th.dt-head-center{text-align:center}table.dataTable tfoot td.dt-head-right,table.dataTable tfoot th.dt-head-right,table.dataTable thead td.dt-head-right,table.dataTable thead th.dt-head-right{text-align:right}table.dataTable tfoot td.dt-head-justify,table.dataTable tfoot th.dt-head-justify,table.dataTable thead td.dt-head-justify,table.dataTable thead th.dt-head-justify{text-align:justify}table.dataTable tfoot td.dt-head-nowrap,table.dataTable tfoot th.dt-head-nowrap,table.dataTable thead td.dt-head-nowrap,table.dataTable thead th.dt-head-nowrap{white-space:nowrap}table.dataTable tbody td.dt-body-left,table.dataTable tbody th.dt-body-left{text-align:left}table.dataTable tbody td.dt-body-center,table.dataTable tbody th.dt-body-center{text-align:center}table.dataTable tbody td.dt-body-right,table.dataTable tbody th.dt-body-right{text-align:right}table.dataTable tbody td.dt-body-justify,table.dataTable tbody th.dt-body-justify{text-align:justify}table.dataTable tbody td.dt-body-nowrap,table.dataTable tbody th.dt-body-nowrap{white-space:nowrap}table.dataTable,table.dataTable td,table.dataTable th{box-sizing:content-box}.dataTables_wrapper{clear:both;position:relative;zoom:1}.dataTables_wrapper .dataTables_length{float:left}.dataTables_wrapper .dataTables_filter{float:right;text-align:right}.dataTables_wrapper .dataTables_filter input{margin-left:.5em}.dataTables_wrapper .dataTables_info{clear:both;float:left;padding-top:.755em}.dataTables_wrapper .dataTables_paginate{float:right;padding-top:.25em;text-align:right}.dataTables_wrapper .dataTables_paginate .paginate_button{border:1px solid transparent;border-radius:3px;box-shadow:none;box-sizing:border-box;color:#555;cursor:pointer;display:inline-block;font-size:13px;height:28px;line-height:26px;margin:0 0 0 2px;padding:0 10px 1px;text-decoration:none;vertical-align:top;white-space:nowrap}.dataTables_wrapper .dataTables_paginate .paginate_button:active,.dataTables_wrapper .dataTables_paginate .paginate_button:hover{background:#fafafa;border-color:#999;color:#23282d}.dataTables_wrapper .dataTables_paginate .paginate_button.next,.dataTables_wrapper .dataTables_paginate .paginate_button.previous{background:transparent;border-color:transparent;box-shadow:none;color:#23282d}.dataTables_wrapper .dataTables_paginate .paginate_button.next.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.previous.disabled{background:transparent;border-color:transparent;box-shadow:none}.dataTables_wrapper .dataTables_paginate .paginate_button.next.disabled:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.previous.disabled:hover{background:transparent;border-color:transparent;box-shadow:none;text-decoration:none}.dataTables_wrapper .dataTables_paginate .paginate_button.next:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.previous:hover{color:#222;text-decoration:underline}.dataTables_wrapper .dataTables_paginate .paginate_button.current,.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover{background:#fcfcfc;border-color:#999;box-shadow:0 1px 0 #ccc;color:#23282d;text-decoration:none}.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover{background:#f7f7f7;border-color:#ddd;box-shadow:none;color:#a0a5aa;cursor:default;text-shadow:0 1px 0 #fff;transform:none}.dataTables_wrapper .dataTables_paginate .ellipsis{padding:0 1em}.dataTables_wrapper .dataTables_processing{position:absolute;top:50%;left:50%;width:100%;height:40px;margin-left:-50%;margin-top:-25px;padding-top:20px;text-align:center;font-size:1.2em;background-color:#fff;background:linear-gradient(90deg,hsla(0,0%,100%,0) 0,hsla(0,0%,100%,.9) 25%,hsla(0,0%,100%,.9) 75%,hsla(0,0%,100%,0))}.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_paginate,.dataTables_wrapper .dataTables_processing{color:#333}.dataTables_wrapper .dataTables_scroll{clear:both}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody{margin-top:-1px;-webkit-overflow-scrolling:touch}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th{vertical-align:middle}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th>div.dataTables_sizing,.dataTables_wrapper .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td>div.dataTables_sizing{height:0;overflow:hidden;margin:0!important;padding:0!important}.dataTables_wrapper.no-footer .dataTables_scrollBody{border-bottom:1px solid #111}.dataTables_wrapper.no-footer div.dataTables_scrollBody table,.dataTables_wrapper.no-footer div.dataTables_scrollHead table{border-bottom:none}.dataTables_wrapper:after{visibility:hidden;display:block;content:"";clear:both;height:0}@media screen and (max-width:767px){.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_paginate{float:none;text-align:center}.dataTables_wrapper .dataTables_paginate{margin-top:.5em}}@media screen and (max-width:640px){.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_length{float:none;text-align:center}.dataTables_wrapper .dataTables_filter{margin-top:.5em}}
|
common/src/resources/postcss/datatables.pcss
CHANGED
@@ -31,23 +31,23 @@ table.dataTable {
|
|
31 |
}
|
32 |
|
33 |
.sorting {
|
34 |
-
background-image: url("../../../vendor/datatables/
|
35 |
}
|
36 |
|
37 |
.sorting_asc {
|
38 |
-
background-image: url("../../../vendor/datatables/
|
39 |
}
|
40 |
|
41 |
.sorting_desc {
|
42 |
-
background-image: url("../../../vendor/datatables/
|
43 |
}
|
44 |
|
45 |
.sorting_asc_disabled {
|
46 |
-
background-image: url("../../../vendor/datatables/
|
47 |
}
|
48 |
|
49 |
.sorting_desc_disabled {
|
50 |
-
background-image: url("../../../vendor/datatables/
|
51 |
}
|
52 |
}
|
53 |
|
31 |
}
|
32 |
|
33 |
.sorting {
|
34 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_both.png");
|
35 |
}
|
36 |
|
37 |
.sorting_asc {
|
38 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_asc.png");
|
39 |
}
|
40 |
|
41 |
.sorting_desc {
|
42 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_desc.png");
|
43 |
}
|
44 |
|
45 |
.sorting_asc_disabled {
|
46 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_asc_disabled.png");
|
47 |
}
|
48 |
|
49 |
.sorting_desc_disabled {
|
50 |
+
background-image: url("../../../vendor/datatables/DataTables/images/sort_desc_disabled.png");
|
51 |
}
|
52 |
}
|
53 |
|
common/tribe-common.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
Description: An event settings framework for managing shared options
|
4 |
-
Version: 4.7.
|
5 |
Author: Modern Tribe, Inc.
|
6 |
Author URI: http://m.tri.be/1x
|
7 |
Text Domain: tribe-common
|
1 |
<?php
|
2 |
/*
|
3 |
Description: An event settings framework for managing shared options
|
4 |
+
Version: 4.7.12
|
5 |
Author: Modern Tribe, Inc.
|
6 |
Author URI: http://m.tri.be/1x
|
7 |
Text Domain: tribe-common
|
common/vendor/datatables/{media → DataTables}/images/sort_asc.png
RENAMED
File without changes
|
common/vendor/datatables/{media → DataTables}/images/sort_asc_disabled.png
RENAMED
File without changes
|
common/vendor/datatables/{media → DataTables}/images/sort_both.png
RENAMED
File without changes
|
common/vendor/datatables/{media → DataTables}/images/sort_desc.png
RENAMED
File without changes
|
common/vendor/datatables/{media → DataTables}/images/sort_desc_disabled.png
RENAMED
File without changes
|
common/vendor/datatables/datatables.css
ADDED
@@ -0,0 +1,1220 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* This combined file was created by the DataTables downloader builder:
|
3 |
+
* https://datatables.net/download
|
4 |
+
*
|
5 |
+
* To rebuild or modify this file with the latest versions of the included
|
6 |
+
* software please visit:
|
7 |
+
* https://datatables.net/download/#dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5
|
8 |
+
*
|
9 |
+
* Included libraries:
|
10 |
+
* DataTables 1.10.16, AutoFill 2.2.2, Buttons 1.5.1, ColReorder 1.4.1, FixedColumns 3.2.4, FixedHeader 3.1.3, KeyTable 2.3.2, Responsive 2.2.1, RowReorder 1.2.3, Scroller 1.4.4, Select 1.2.5
|
11 |
+
*/
|
12 |
+
|
13 |
+
/*
|
14 |
+
* Table styles
|
15 |
+
*/
|
16 |
+
table.dataTable {
|
17 |
+
width: 100%;
|
18 |
+
margin: 0 auto;
|
19 |
+
clear: both;
|
20 |
+
border-collapse: separate;
|
21 |
+
border-spacing: 0;
|
22 |
+
/*
|
23 |
+
* Header and footer styles
|
24 |
+
*/
|
25 |
+
/*
|
26 |
+
* Body styles
|
27 |
+
*/
|
28 |
+
}
|
29 |
+
table.dataTable thead th,
|
30 |
+
table.dataTable tfoot th {
|
31 |
+
font-weight: bold;
|
32 |
+
}
|
33 |
+
table.dataTable thead th,
|
34 |
+
table.dataTable thead td {
|
35 |
+
padding: 10px 18px;
|
36 |
+
border-bottom: 1px solid #111;
|
37 |
+
}
|
38 |
+
table.dataTable thead th:active,
|
39 |
+
table.dataTable thead td:active {
|
40 |
+
outline: none;
|
41 |
+
}
|
42 |
+
table.dataTable tfoot th,
|
43 |
+
table.dataTable tfoot td {
|
44 |
+
padding: 10px 18px 6px 18px;
|
45 |
+
border-top: 1px solid #111;
|
46 |
+
}
|
47 |
+
table.dataTable thead .sorting,
|
48 |
+
table.dataTable thead .sorting_asc,
|
49 |
+
table.dataTable thead .sorting_desc,
|
50 |
+
table.dataTable thead .sorting_asc_disabled,
|
51 |
+
table.dataTable thead .sorting_desc_disabled {
|
52 |
+
cursor: pointer;
|
53 |
+
*cursor: hand;
|
54 |
+
background-repeat: no-repeat;
|
55 |
+
background-position: center right;
|
56 |
+
}
|
57 |
+
table.dataTable thead .sorting {
|
58 |
+
background-image: url("DataTables-1.10.16/images/sort_both.png");
|
59 |
+
}
|
60 |
+
table.dataTable thead .sorting_asc {
|
61 |
+
background-image: url("DataTables-1.10.16/images/sort_asc.png");
|
62 |
+
}
|
63 |
+
table.dataTable thead .sorting_desc {
|
64 |
+
background-image: url("DataTables-1.10.16/images/sort_desc.png");
|
65 |
+
}
|
66 |
+
table.dataTable thead .sorting_asc_disabled {
|
67 |
+
background-image: url("DataTables-1.10.16/images/sort_asc_disabled.png");
|
68 |
+
}
|
69 |
+
table.dataTable thead .sorting_desc_disabled {
|
70 |
+
background-image: url("DataTables-1.10.16/images/sort_desc_disabled.png");
|
71 |
+
}
|
72 |
+
table.dataTable tbody tr {
|
73 |
+
background-color: #ffffff;
|
74 |
+
}
|
75 |
+
table.dataTable tbody tr.selected {
|
76 |
+
background-color: #B0BED9;
|
77 |
+
}
|
78 |
+
table.dataTable tbody th,
|
79 |
+
table.dataTable tbody td {
|
80 |
+
padding: 8px 10px;
|
81 |
+
}
|
82 |
+
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
83 |
+
border-top: 1px solid #ddd;
|
84 |
+
}
|
85 |
+
table.dataTable.row-border tbody tr:first-child th,
|
86 |
+
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
87 |
+
table.dataTable.display tbody tr:first-child td {
|
88 |
+
border-top: none;
|
89 |
+
}
|
90 |
+
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
91 |
+
border-top: 1px solid #ddd;
|
92 |
+
border-right: 1px solid #ddd;
|
93 |
+
}
|
94 |
+
table.dataTable.cell-border tbody tr th:first-child,
|
95 |
+
table.dataTable.cell-border tbody tr td:first-child {
|
96 |
+
border-left: 1px solid #ddd;
|
97 |
+
}
|
98 |
+
table.dataTable.cell-border tbody tr:first-child th,
|
99 |
+
table.dataTable.cell-border tbody tr:first-child td {
|
100 |
+
border-top: none;
|
101 |
+
}
|
102 |
+
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
103 |
+
background-color: #f9f9f9;
|
104 |
+
}
|
105 |
+
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
106 |
+
background-color: #acbad4;
|
107 |
+
}
|
108 |
+
table.dataTable.hover tbody tr:hover, table.dataTable.display tbody tr:hover {
|
109 |
+
background-color: #f6f6f6;
|
110 |
+
}
|
111 |
+
table.dataTable.hover tbody tr:hover.selected, table.dataTable.display tbody tr:hover.selected {
|
112 |
+
background-color: #aab7d1;
|
113 |
+
}
|
114 |
+
table.dataTable.order-column tbody tr > .sorting_1,
|
115 |
+
table.dataTable.order-column tbody tr > .sorting_2,
|
116 |
+
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
117 |
+
table.dataTable.display tbody tr > .sorting_2,
|
118 |
+
table.dataTable.display tbody tr > .sorting_3 {
|
119 |
+
background-color: #fafafa;
|
120 |
+
}
|
121 |
+
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
122 |
+
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
123 |
+
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
124 |
+
table.dataTable.display tbody tr.selected > .sorting_2,
|
125 |
+
table.dataTable.display tbody tr.selected > .sorting_3 {
|
126 |
+
background-color: #acbad5;
|
127 |
+
}
|
128 |
+
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
129 |
+
background-color: #f1f1f1;
|
130 |
+
}
|
131 |
+
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
132 |
+
background-color: #f3f3f3;
|
133 |
+
}
|
134 |
+
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
135 |
+
background-color: whitesmoke;
|
136 |
+
}
|
137 |
+
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
138 |
+
background-color: #a6b4cd;
|
139 |
+
}
|
140 |
+
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
141 |
+
background-color: #a8b5cf;
|
142 |
+
}
|
143 |
+
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
144 |
+
background-color: #a9b7d1;
|
145 |
+
}
|
146 |
+
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
147 |
+
background-color: #fafafa;
|
148 |
+
}
|
149 |
+
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
150 |
+
background-color: #fcfcfc;
|
151 |
+
}
|
152 |
+
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
153 |
+
background-color: #fefefe;
|
154 |
+
}
|
155 |
+
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
156 |
+
background-color: #acbad5;
|
157 |
+
}
|
158 |
+
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
159 |
+
background-color: #aebcd6;
|
160 |
+
}
|
161 |
+
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
162 |
+
background-color: #afbdd8;
|
163 |
+
}
|
164 |
+
table.dataTable.display tbody tr:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1 {
|
165 |
+
background-color: #eaeaea;
|
166 |
+
}
|
167 |
+
table.dataTable.display tbody tr:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2 {
|
168 |
+
background-color: #ececec;
|
169 |
+
}
|
170 |
+
table.dataTable.display tbody tr:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3 {
|
171 |
+
background-color: #efefef;
|
172 |
+
}
|
173 |
+
table.dataTable.display tbody tr:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1 {
|
174 |
+
background-color: #a2aec7;
|
175 |
+
}
|
176 |
+
table.dataTable.display tbody tr:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2 {
|
177 |
+
background-color: #a3b0c9;
|
178 |
+
}
|
179 |
+
table.dataTable.display tbody tr:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3 {
|
180 |
+
background-color: #a5b2cb;
|
181 |
+
}
|
182 |
+
table.dataTable.no-footer {
|
183 |
+
border-bottom: 1px solid #111;
|
184 |
+
}
|
185 |
+
table.dataTable.nowrap th, table.dataTable.nowrap td {
|
186 |
+
white-space: nowrap;
|
187 |
+
}
|
188 |
+
table.dataTable.compact thead th,
|
189 |
+
table.dataTable.compact thead td {
|
190 |
+
padding: 4px 17px 4px 4px;
|
191 |
+
}
|
192 |
+
table.dataTable.compact tfoot th,
|
193 |
+
table.dataTable.compact tfoot td {
|
194 |
+
padding: 4px;
|
195 |
+
}
|
196 |
+
table.dataTable.compact tbody th,
|
197 |
+
table.dataTable.compact tbody td {
|
198 |
+
padding: 4px;
|
199 |
+
}
|
200 |
+
table.dataTable th.dt-left,
|
201 |
+
table.dataTable td.dt-left {
|
202 |
+
text-align: left;
|
203 |
+
}
|
204 |
+
table.dataTable th.dt-center,
|
205 |
+
table.dataTable td.dt-center,
|
206 |
+
table.dataTable td.dataTables_empty {
|
207 |
+
text-align: center;
|
208 |
+
}
|
209 |
+
table.dataTable th.dt-right,
|
210 |
+
table.dataTable td.dt-right {
|
211 |
+
text-align: right;
|
212 |
+
}
|
213 |
+
table.dataTable th.dt-justify,
|
214 |
+
table.dataTable td.dt-justify {
|
215 |
+
text-align: justify;
|
216 |
+
}
|
217 |
+
table.dataTable th.dt-nowrap,
|
218 |
+
table.dataTable td.dt-nowrap {
|
219 |
+
white-space: nowrap;
|
220 |
+
}
|
221 |
+
table.dataTable thead th.dt-head-left,
|
222 |
+
table.dataTable thead td.dt-head-left,
|
223 |
+
table.dataTable tfoot th.dt-head-left,
|
224 |
+
table.dataTable tfoot td.dt-head-left {
|
225 |
+
text-align: left;
|
226 |
+
}
|
227 |
+
table.dataTable thead th.dt-head-center,
|
228 |
+
table.dataTable thead td.dt-head-center,
|
229 |
+
table.dataTable tfoot th.dt-head-center,
|
230 |
+
table.dataTable tfoot td.dt-head-center {
|
231 |
+
text-align: center;
|
232 |
+
}
|
233 |
+
table.dataTable thead th.dt-head-right,
|
234 |
+
table.dataTable thead td.dt-head-right,
|
235 |
+
table.dataTable tfoot th.dt-head-right,
|
236 |
+
table.dataTable tfoot td.dt-head-right {
|
237 |
+
text-align: right;
|
238 |
+
}
|
239 |
+
table.dataTable thead th.dt-head-justify,
|
240 |
+
table.dataTable thead td.dt-head-justify,
|
241 |
+
table.dataTable tfoot th.dt-head-justify,
|
242 |
+
table.dataTable tfoot td.dt-head-justify {
|
243 |
+
text-align: justify;
|
244 |
+
}
|
245 |
+
table.dataTable thead th.dt-head-nowrap,
|
246 |
+
table.dataTable thead td.dt-head-nowrap,
|
247 |
+
table.dataTable tfoot th.dt-head-nowrap,
|
248 |
+
table.dataTable tfoot td.dt-head-nowrap {
|
249 |
+
white-space: nowrap;
|
250 |
+
}
|
251 |
+
table.dataTable tbody th.dt-body-left,
|
252 |
+
table.dataTable tbody td.dt-body-left {
|
253 |
+
text-align: left;
|
254 |
+
}
|
255 |
+
table.dataTable tbody th.dt-body-center,
|
256 |
+
table.dataTable tbody td.dt-body-center {
|
257 |
+
text-align: center;
|
258 |
+
}
|
259 |
+
table.dataTable tbody th.dt-body-right,
|
260 |
+
table.dataTable tbody td.dt-body-right {
|
261 |
+
text-align: right;
|
262 |
+
}
|
263 |
+
table.dataTable tbody th.dt-body-justify,
|
264 |
+
table.dataTable tbody td.dt-body-justify {
|
265 |
+
text-align: justify;
|
266 |
+
}
|
267 |
+
table.dataTable tbody th.dt-body-nowrap,
|
268 |
+
table.dataTable tbody td.dt-body-nowrap {
|
269 |
+
white-space: nowrap;
|
270 |
+
}
|
271 |
+
|
272 |
+
table.dataTable,
|
273 |
+
table.dataTable th,
|
274 |
+
table.dataTable td {
|
275 |
+
box-sizing: content-box;
|
276 |
+
}
|
277 |
+
|
278 |
+
/*
|
279 |
+
* Control feature layout
|
280 |
+
*/
|
281 |
+
.dataTables_wrapper {
|
282 |
+
position: relative;
|
283 |
+
clear: both;
|
284 |
+
*zoom: 1;
|
285 |
+
zoom: 1;
|
286 |
+
}
|
287 |
+
.dataTables_wrapper .dataTables_length {
|
288 |
+
float: left;
|
289 |
+
}
|
290 |
+
.dataTables_wrapper .dataTables_filter {
|
291 |
+
float: right;
|
292 |
+
text-align: right;
|
293 |
+
}
|
294 |
+
.dataTables_wrapper .dataTables_filter input {
|
295 |
+
margin-left: 0.5em;
|
296 |
+
}
|
297 |
+
.dataTables_wrapper .dataTables_info {
|
298 |
+
clear: both;
|
299 |
+
float: left;
|
300 |
+
padding-top: 0.755em;
|
301 |
+
}
|
302 |
+
.dataTables_wrapper .dataTables_paginate {
|
303 |
+
float: right;
|
304 |
+
text-align: right;
|
305 |
+
padding-top: 0.25em;
|
306 |
+
}
|
307 |
+
.dataTables_wrapper .dataTables_paginate .paginate_button {
|
308 |
+
box-sizing: border-box;
|
309 |
+
display: inline-block;
|
310 |
+
min-width: 1.5em;
|
311 |
+
padding: 0.5em 1em;
|
312 |
+
margin-left: 2px;
|
313 |
+
text-align: center;
|
314 |
+
text-decoration: none !important;
|
315 |
+
cursor: pointer;
|
316 |
+
*cursor: hand;
|
317 |
+
color: #333 !important;
|
318 |
+
border: 1px solid transparent;
|
319 |
+
border-radius: 2px;
|
320 |
+
}
|
321 |
+
.dataTables_wrapper .dataTables_paginate .paginate_button.current, .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
|
322 |
+
color: #333 !important;
|
323 |
+
border: 1px solid #979797;
|
324 |
+
background-color: white;
|
325 |
+
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, white), color-stop(100%, #dcdcdc));
|
326 |
+
/* Chrome,Safari4+ */
|
327 |
+
background: -webkit-linear-gradient(top, white 0%, #dcdcdc 100%);
|
328 |
+
/* Chrome10+,Safari5.1+ */
|
329 |
+
background: -moz-linear-gradient(top, white 0%, #dcdcdc 100%);
|
330 |
+
/* FF3.6+ */
|
331 |
+
background: -ms-linear-gradient(top, white 0%, #dcdcdc 100%);
|
332 |
+
/* IE10+ */
|
333 |
+
background: -o-linear-gradient(top, white 0%, #dcdcdc 100%);
|
334 |
+
/* Opera 11.10+ */
|
335 |
+
background: linear-gradient(to bottom, white 0%, #dcdcdc 100%);
|
336 |
+
/* W3C */
|
337 |
+
}
|
338 |
+
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active {
|
339 |
+
cursor: default;
|
340 |
+
color: #666 !important;
|
341 |
+
border: 1px solid transparent;
|
342 |
+
background: transparent;
|
343 |
+
box-shadow: none;
|
344 |
+
}
|
345 |
+
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
|
346 |
+
color: white !important;
|
347 |
+
border: 1px solid #111;
|
348 |
+
background-color: #585858;
|
349 |
+
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #585858), color-stop(100%, #111));
|
350 |
+
/* Chrome,Safari4+ */
|
351 |
+
background: -webkit-linear-gradient(top, #585858 0%, #111 100%);
|
352 |
+
/* Chrome10+,Safari5.1+ */
|
353 |
+
background: -moz-linear-gradient(top, #585858 0%, #111 100%);
|
354 |
+
/* FF3.6+ */
|
355 |
+
background: -ms-linear-gradient(top, #585858 0%, #111 100%);
|
356 |
+
/* IE10+ */
|
357 |
+
background: -o-linear-gradient(top, #585858 0%, #111 100%);
|
358 |
+
/* Opera 11.10+ */
|
359 |
+
background: linear-gradient(to bottom, #585858 0%, #111 100%);
|
360 |
+
/* W3C */
|
361 |
+
}
|
362 |
+
.dataTables_wrapper .dataTables_paginate .paginate_button:active {
|
363 |
+
outline: none;
|
364 |
+
background-color: #2b2b2b;
|
365 |
+
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #2b2b2b), color-stop(100%, #0c0c0c));
|
366 |
+
/* Chrome,Safari4+ */
|
367 |
+
background: -webkit-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
368 |
+
/* Chrome10+,Safari5.1+ */
|
369 |
+
background: -moz-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
370 |
+
/* FF3.6+ */
|
371 |
+
background: -ms-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
372 |
+
/* IE10+ */
|
373 |
+
background: -o-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
374 |
+
/* Opera 11.10+ */
|
375 |
+
background: linear-gradient(to bottom, #2b2b2b 0%, #0c0c0c 100%);
|
376 |
+
/* W3C */
|
377 |
+
box-shadow: inset 0 0 3px #111;
|
378 |
+
}
|
379 |
+
.dataTables_wrapper .dataTables_paginate .ellipsis {
|
380 |
+
padding: 0 1em;
|
381 |
+
}
|
382 |
+
.dataTables_wrapper .dataTables_processing {
|
383 |
+
position: absolute;
|
384 |
+
top: 50%;
|
385 |
+
left: 50%;
|
386 |
+
width: 100%;
|
387 |
+
height: 40px;
|
388 |
+
margin-left: -50%;
|
389 |
+
margin-top: -25px;
|
390 |
+
padding-top: 20px;
|
391 |
+
text-align: center;
|
392 |
+
font-size: 1.2em;
|
393 |
+
background-color: white;
|
394 |
+
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0)), color-stop(25%, rgba(255, 255, 255, 0.9)), color-stop(75%, rgba(255, 255, 255, 0.9)), color-stop(100%, rgba(255, 255, 255, 0)));
|
395 |
+
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
396 |
+
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
397 |
+
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
398 |
+
background: -o-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
399 |
+
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
400 |
+
}
|
401 |
+
.dataTables_wrapper .dataTables_length,
|
402 |
+
.dataTables_wrapper .dataTables_filter,
|
403 |
+
.dataTables_wrapper .dataTables_info,
|
404 |
+
.dataTables_wrapper .dataTables_processing,
|
405 |
+
.dataTables_wrapper .dataTables_paginate {
|
406 |
+
color: #333;
|
407 |
+
}
|
408 |
+
.dataTables_wrapper .dataTables_scroll {
|
409 |
+
clear: both;
|
410 |
+
}
|
411 |
+
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody {
|
412 |
+
*margin-top: -1px;
|
413 |
+
-webkit-overflow-scrolling: touch;
|
414 |
+
}
|
415 |
+
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > thead > tr > th, .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > thead > tr > td, .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > tbody > tr > th, .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > tbody > tr > td {
|
416 |
+
vertical-align: middle;
|
417 |
+
}
|
418 |
+
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > thead > tr > th > div.dataTables_sizing,
|
419 |
+
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > thead > tr > td > div.dataTables_sizing, .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > tbody > tr > th > div.dataTables_sizing,
|
420 |
+
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody > table > tbody > tr > td > div.dataTables_sizing {
|
421 |
+
height: 0;
|
422 |
+
overflow: hidden;
|
423 |
+
margin: 0 !important;
|
424 |
+
padding: 0 !important;
|
425 |
+
}
|
426 |
+
.dataTables_wrapper.no-footer .dataTables_scrollBody {
|
427 |
+
border-bottom: 1px solid #111;
|
428 |
+
}
|
429 |
+
.dataTables_wrapper.no-footer div.dataTables_scrollHead table.dataTable,
|
430 |
+
.dataTables_wrapper.no-footer div.dataTables_scrollBody > table {
|
431 |
+
border-bottom: none;
|
432 |
+
}
|
433 |
+
.dataTables_wrapper:after {
|
434 |
+
visibility: hidden;
|
435 |
+
display: block;
|
436 |
+
content: "";
|
437 |
+
clear: both;
|
438 |
+
height: 0;
|
439 |
+
}
|
440 |
+
|
441 |
+
@media screen and (max-width: 767px) {
|
442 |
+
.dataTables_wrapper .dataTables_info,
|
443 |
+
.dataTables_wrapper .dataTables_paginate {
|
444 |
+
float: none;
|
445 |
+
text-align: center;
|
446 |
+
}
|
447 |
+
.dataTables_wrapper .dataTables_paginate {
|
448 |
+
margin-top: 0.5em;
|
449 |
+
}
|
450 |
+
}
|
451 |
+
@media screen and (max-width: 640px) {
|
452 |
+
.dataTables_wrapper .dataTables_length,
|
453 |
+
.dataTables_wrapper .dataTables_filter {
|
454 |
+
float: none;
|
455 |
+
text-align: center;
|
456 |
+
}
|
457 |
+
.dataTables_wrapper .dataTables_filter {
|
458 |
+
margin-top: 0.5em;
|
459 |
+
}
|
460 |
+
}
|
461 |
+
|
462 |
+
|
463 |
+
div.dt-autofill-handle{position:absolute;height:8px;width:8px;z-index:102;box-sizing:border-box;border:1px solid #316ad1;background:linear-gradient(to bottom, #abcffb 0%, #4989de 100%)}div.dt-autofill-select{position:absolute;z-index:1001;background-color:#4989de;background-image:repeating-linear-gradient(45deg, transparent, transparent 5px, rgba(255,255,255,0.5) 5px, rgba(255,255,255,0.5) 10px)}div.dt-autofill-select.top,div.dt-autofill-select.bottom{height:3px;margin-top:-1px}div.dt-autofill-select.left,div.dt-autofill-select.right{width:3px;margin-left:-1px}div.dt-autofill-list{position:fixed;top:50%;left:50%;width:500px;margin-left:-250px;background-color:white;border-radius:6px;box-shadow:0 0 5px #555;border:2px solid #444;z-index:11;box-sizing:border-box;padding:1.5em 2em}div.dt-autofill-list ul{display:table;margin:0;padding:0;list-style:none;width:100%}div.dt-autofill-list ul li{display:table-row}div.dt-autofill-list ul li:last-child div.dt-autofill-question,div.dt-autofill-list ul li:last-child div.dt-autofill-button{border-bottom:none}div.dt-autofill-list ul li:hover{background-color:#f6f6f6}div.dt-autofill-list div.dt-autofill-question{display:table-cell;padding:0.5em 0;border-bottom:1px solid #ccc}div.dt-autofill-list div.dt-autofill-question input[type=number]{padding:6px;width:30px;margin:-2px 0}div.dt-autofill-list div.dt-autofill-button{display:table-cell;padding:0.5em 0;border-bottom:1px solid #ccc}div.dt-autofill-list div.dt-autofill-button button{color:white;margin:0;padding:6px 12px;text-align:center;border:1px solid #2e6da4;background-color:#337ab7;border-radius:4px;cursor:pointer;vertical-align:middle}div.dt-autofill-background{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,0.7);background:radial-gradient(ellipse farthest-corner at center, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);z-index:10}
|
464 |
+
|
465 |
+
|
466 |
+
@keyframes dtb-spinner {
|
467 |
+
100% {
|
468 |
+
transform: rotate(360deg);
|
469 |
+
}
|
470 |
+
}
|
471 |
+
@-o-keyframes dtb-spinner {
|
472 |
+
100% {
|
473 |
+
-o-transform: rotate(360deg);
|
474 |
+
transform: rotate(360deg);
|
475 |
+
}
|
476 |
+
}
|
477 |
+
@-ms-keyframes dtb-spinner {
|
478 |
+
100% {
|
479 |
+
-ms-transform: rotate(360deg);
|
480 |
+
transform: rotate(360deg);
|
481 |
+
}
|
482 |
+
}
|
483 |
+
@-webkit-keyframes dtb-spinner {
|
484 |
+
100% {
|
485 |
+
-webkit-transform: rotate(360deg);
|
486 |
+
transform: rotate(360deg);
|
487 |
+
}
|
488 |
+
}
|
489 |
+
@-moz-keyframes dtb-spinner {
|
490 |
+
100% {
|
491 |
+
-moz-transform: rotate(360deg);
|
492 |
+
transform: rotate(360deg);
|
493 |
+
}
|
494 |
+
}
|
495 |
+
div.dt-button-info {
|
496 |
+
position: fixed;
|
497 |
+
top: 50%;
|
498 |
+
left: 50%;
|
499 |
+
width: 400px;
|
500 |
+
margin-top: -100px;
|
501 |
+
margin-left: -200px;
|
502 |
+
background-color: white;
|
503 |
+
border: 2px solid #111;
|
504 |
+
box-shadow: 3px 3px 8px rgba(0, 0, 0, 0.3);
|
505 |
+
border-radius: 3px;
|
506 |
+
text-align: center;
|
507 |
+
z-index: 21;
|
508 |
+
}
|
509 |
+
div.dt-button-info h2 {
|
510 |
+
padding: 0.5em;
|
511 |
+
margin: 0;
|
512 |
+
font-weight: normal;
|
513 |
+
border-bottom: 1px solid #ddd;
|
514 |
+
background-color: #f3f3f3;
|
515 |
+
}
|
516 |
+
div.dt-button-info > div {
|
517 |
+
padding: 1em;
|
518 |
+
}
|
519 |
+
|
520 |
+
button.dt-button,
|
521 |
+
div.dt-button,
|
522 |
+
a.dt-button {
|
523 |
+
position: relative;
|
524 |
+
display: inline-block;
|
525 |
+
box-sizing: border-box;
|
526 |
+
margin-right: 0.333em;
|
527 |
+
margin-bottom: 0.333em;
|
528 |
+
padding: 0.5em 1em;
|
529 |
+
border: 1px solid #999;
|
530 |
+
border-radius: 2px;
|
531 |
+
cursor: pointer;
|
532 |
+
font-size: 0.88em;
|
533 |
+
line-height: 1.6em;
|
534 |
+
color: black;
|
535 |
+
white-space: nowrap;
|
536 |
+
overflow: hidden;
|
537 |
+
background-color: #e9e9e9;
|
538 |
+
/* Fallback */
|
539 |
+
background-image: -webkit-linear-gradient(top, white 0%, #e9e9e9 100%);
|
540 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
541 |
+
background-image: -moz-linear-gradient(top, white 0%, #e9e9e9 100%);
|
542 |
+
/* FF3.6 */
|
543 |
+
background-image: -ms-linear-gradient(top, white 0%, #e9e9e9 100%);
|
544 |
+
/* IE10 */
|
545 |
+
background-image: -o-linear-gradient(top, white 0%, #e9e9e9 100%);
|
546 |
+
/* Opera 11.10+ */
|
547 |
+
background-image: linear-gradient(to bottom, white 0%, #e9e9e9 100%);
|
548 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='white', EndColorStr='#e9e9e9');
|
549 |
+
-webkit-user-select: none;
|
550 |
+
-moz-user-select: none;
|
551 |
+
-ms-user-select: none;
|
552 |
+
user-select: none;
|
553 |
+
text-decoration: none;
|
554 |
+
outline: none;
|
555 |
+
}
|
556 |
+
button.dt-button.disabled,
|
557 |
+
div.dt-button.disabled,
|
558 |
+
a.dt-button.disabled {
|
559 |
+
color: #999;
|
560 |
+
border: 1px solid #d0d0d0;
|
561 |
+
cursor: default;
|
562 |
+
background-color: #f9f9f9;
|
563 |
+
/* Fallback */
|
564 |
+
background-image: -webkit-linear-gradient(top, #ffffff 0%, #f9f9f9 100%);
|
565 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
566 |
+
background-image: -moz-linear-gradient(top, #ffffff 0%, #f9f9f9 100%);
|
567 |
+
/* FF3.6 */
|
568 |
+
background-image: -ms-linear-gradient(top, #ffffff 0%, #f9f9f9 100%);
|
569 |
+
/* IE10 */
|
570 |
+
background-image: -o-linear-gradient(top, #ffffff 0%, #f9f9f9 100%);
|
571 |
+
/* Opera 11.10+ */
|
572 |
+
background-image: linear-gradient(to bottom, #ffffff 0%, #f9f9f9 100%);
|
573 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#ffffff', EndColorStr='#f9f9f9');
|
574 |
+
}
|
575 |
+
button.dt-button:active:not(.disabled), button.dt-button.active:not(.disabled),
|
576 |
+
div.dt-button:active:not(.disabled),
|
577 |
+
div.dt-button.active:not(.disabled),
|
578 |
+
a.dt-button:active:not(.disabled),
|
579 |
+
a.dt-button.active:not(.disabled) {
|
580 |
+
background-color: #e2e2e2;
|
581 |
+
/* Fallback */
|
582 |
+
background-image: -webkit-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);
|
583 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
584 |
+
background-image: -moz-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);
|
585 |
+
/* FF3.6 */
|
586 |
+
background-image: -ms-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);
|
587 |
+
/* IE10 */
|
588 |
+
background-image: -o-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);
|
589 |
+
/* Opera 11.10+ */
|
590 |
+
background-image: linear-gradient(to bottom, #f3f3f3 0%, #e2e2e2 100%);
|
591 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f3f3f3', EndColorStr='#e2e2e2');
|
592 |
+
box-shadow: inset 1px 1px 3px #999999;
|
593 |
+
}
|
594 |
+
button.dt-button:active:not(.disabled):hover:not(.disabled), button.dt-button.active:not(.disabled):hover:not(.disabled),
|
595 |
+
div.dt-button:active:not(.disabled):hover:not(.disabled),
|
596 |
+
div.dt-button.active:not(.disabled):hover:not(.disabled),
|
597 |
+
a.dt-button:active:not(.disabled):hover:not(.disabled),
|
598 |
+
a.dt-button.active:not(.disabled):hover:not(.disabled) {
|
599 |
+
box-shadow: inset 1px 1px 3px #999999;
|
600 |
+
background-color: #cccccc;
|
601 |
+
/* Fallback */
|
602 |
+
background-image: -webkit-linear-gradient(top, #eaeaea 0%, #cccccc 100%);
|
603 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
604 |
+
background-image: -moz-linear-gradient(top, #eaeaea 0%, #cccccc 100%);
|
605 |
+
/* FF3.6 */
|
606 |
+
background-image: -ms-linear-gradient(top, #eaeaea 0%, #cccccc 100%);
|
607 |
+
/* IE10 */
|
608 |
+
background-image: -o-linear-gradient(top, #eaeaea 0%, #cccccc 100%);
|
609 |
+
/* Opera 11.10+ */
|
610 |
+
background-image: linear-gradient(to bottom, #eaeaea 0%, #cccccc 100%);
|
611 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#eaeaea', EndColorStr='#cccccc');
|
612 |
+
}
|
613 |
+
button.dt-button:hover,
|
614 |
+
div.dt-button:hover,
|
615 |
+
a.dt-button:hover {
|
616 |
+
text-decoration: none;
|
617 |
+
}
|
618 |
+
button.dt-button:hover:not(.disabled),
|
619 |
+
div.dt-button:hover:not(.disabled),
|
620 |
+
a.dt-button:hover:not(.disabled) {
|
621 |
+
border: 1px solid #666;
|
622 |
+
background-color: #e0e0e0;
|
623 |
+
/* Fallback */
|
624 |
+
background-image: -webkit-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);
|
625 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
626 |
+
background-image: -moz-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);
|
627 |
+
/* FF3.6 */
|
628 |
+
background-image: -ms-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);
|
629 |
+
/* IE10 */
|
630 |
+
background-image: -o-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);
|
631 |
+
/* Opera 11.10+ */
|
632 |
+
background-image: linear-gradient(to bottom, #f9f9f9 0%, #e0e0e0 100%);
|
633 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f9f9f9', EndColorStr='#e0e0e0');
|
634 |
+
}
|
635 |
+
button.dt-button:focus:not(.disabled),
|
636 |
+
div.dt-button:focus:not(.disabled),
|
637 |
+
a.dt-button:focus:not(.disabled) {
|
638 |
+
border: 1px solid #426c9e;
|
639 |
+
text-shadow: 0 1px 0 #c4def1;
|
640 |
+
outline: none;
|
641 |
+
background-color: #79ace9;
|
642 |
+
/* Fallback */
|
643 |
+
background-image: -webkit-linear-gradient(top, #bddef4 0%, #79ace9 100%);
|
644 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
645 |
+
background-image: -moz-linear-gradient(top, #bddef4 0%, #79ace9 100%);
|
646 |
+
/* FF3.6 */
|
647 |
+
background-image: -ms-linear-gradient(top, #bddef4 0%, #79ace9 100%);
|
648 |
+
/* IE10 */
|
649 |
+
background-image: -o-linear-gradient(top, #bddef4 0%, #79ace9 100%);
|
650 |
+
/* Opera 11.10+ */
|
651 |
+
background-image: linear-gradient(to bottom, #bddef4 0%, #79ace9 100%);
|
652 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#bddef4', EndColorStr='#79ace9');
|
653 |
+
}
|
654 |
+
|
655 |
+
.dt-button embed {
|
656 |
+
outline: none;
|
657 |
+
}
|
658 |
+
|
659 |
+
div.dt-buttons {
|
660 |
+
position: relative;
|
661 |
+
float: left;
|
662 |
+
}
|
663 |
+
div.dt-buttons.buttons-right {
|
664 |
+
float: right;
|
665 |
+
}
|
666 |
+
|
667 |
+
div.dt-button-collection {
|
668 |
+
position: absolute;
|
669 |
+
top: 0;
|
670 |
+
left: 0;
|
671 |
+
width: 150px;
|
672 |
+
margin-top: 3px;
|
673 |
+
padding: 8px 8px 4px 8px;
|
674 |
+
border: 1px solid #ccc;
|
675 |
+
border: 1px solid rgba(0, 0, 0, 0.4);
|
676 |
+
background-color: white;
|
677 |
+
overflow: hidden;
|
678 |
+
z-index: 2002;
|
679 |
+
border-radius: 5px;
|
680 |
+
box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
681 |
+
z-index: 2002;
|
682 |
+
-webkit-column-gap: 8px;
|
683 |
+
-moz-column-gap: 8px;
|
684 |
+
-ms-column-gap: 8px;
|
685 |
+
-o-column-gap: 8px;
|
686 |
+
column-gap: 8px;
|
687 |
+
}
|
688 |
+
div.dt-button-collection button.dt-button,
|
689 |
+
div.dt-button-collection div.dt-button,
|
690 |
+
div.dt-button-collection a.dt-button {
|
691 |
+
position: relative;
|
692 |
+
left: 0;
|
693 |
+
right: 0;
|
694 |
+
width: 100%;
|
695 |
+
display: block;
|
696 |
+
float: none;
|
697 |
+
margin-bottom: 4px;
|
698 |
+
margin-right: 0;
|
699 |
+
}
|
700 |
+
div.dt-button-collection button.dt-button:active:not(.disabled), div.dt-button-collection button.dt-button.active:not(.disabled),
|
701 |
+
div.dt-button-collection div.dt-button:active:not(.disabled),
|
702 |
+
div.dt-button-collection div.dt-button.active:not(.disabled),
|
703 |
+
div.dt-button-collection a.dt-button:active:not(.disabled),
|
704 |
+
div.dt-button-collection a.dt-button.active:not(.disabled) {
|
705 |
+
background-color: #dadada;
|
706 |
+
/* Fallback */
|
707 |
+
background-image: -webkit-linear-gradient(top, #f0f0f0 0%, #dadada 100%);
|
708 |
+
/* Chrome 10+, Saf5.1+, iOS 5+ */
|
709 |
+
background-image: -moz-linear-gradient(top, #f0f0f0 0%, #dadada 100%);
|
710 |
+
/* FF3.6 */
|
711 |
+
background-image: -ms-linear-gradient(top, #f0f0f0 0%, #dadada 100%);
|
712 |
+
/* IE10 */
|
713 |
+
background-image: -o-linear-gradient(top, #f0f0f0 0%, #dadada 100%);
|
714 |
+
/* Opera 11.10+ */
|
715 |
+
background-image: linear-gradient(to bottom, #f0f0f0 0%, #dadada 100%);
|
716 |
+
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f0f0f0', EndColorStr='#dadada');
|
717 |
+
box-shadow: inset 1px 1px 3px #666;
|
718 |
+
}
|
719 |
+
div.dt-button-collection.fixed {
|
720 |
+
position: fixed;
|
721 |
+
top: 50%;
|
722 |
+
left: 50%;
|
723 |
+
margin-left: -75px;
|
724 |
+
border-radius: 0;
|
725 |
+
}
|
726 |
+
div.dt-button-collection.fixed.two-column {
|
727 |
+
margin-left: -150px;
|
728 |
+
}
|
729 |
+
div.dt-button-collection.fixed.three-column {
|
730 |
+
margin-left: -225px;
|
731 |
+
}
|
732 |
+
div.dt-button-collection.fixed.four-column {
|
733 |
+
margin-left: -300px;
|
734 |
+
}
|
735 |
+
div.dt-button-collection > * {
|
736 |
+
-webkit-column-break-inside: avoid;
|
737 |
+
break-inside: avoid;
|
738 |
+
}
|
739 |
+
div.dt-button-collection.two-column {
|
740 |
+
width: 300px;
|
741 |
+
padding-bottom: 1px;
|
742 |
+
-webkit-column-count: 2;
|
743 |
+
-moz-column-count: 2;
|
744 |
+
-ms-column-count: 2;
|
745 |
+
-o-column-count: 2;
|
746 |
+
column-count: 2;
|
747 |
+
}
|
748 |
+
div.dt-button-collection.three-column {
|
749 |
+
width: 450px;
|
750 |
+
padding-bottom: 1px;
|
751 |
+
-webkit-column-count: 3;
|
752 |
+
-moz-column-count: 3;
|
753 |
+
-ms-column-count: 3;
|
754 |
+
-o-column-count: 3;
|
755 |
+
column-count: 3;
|
756 |
+
}
|
757 |
+
div.dt-button-collection.four-column {
|
758 |
+
width: 600px;
|
759 |
+
padding-bottom: 1px;
|
760 |
+
-webkit-column-count: 4;
|
761 |
+
-moz-column-count: 4;
|
762 |
+
-ms-column-count: 4;
|
763 |
+
-o-column-count: 4;
|
764 |
+
column-count: 4;
|
765 |
+
}
|
766 |
+
div.dt-button-collection .dt-button {
|
767 |
+
border-radius: 0;
|
768 |
+
}
|
769 |
+
|
770 |
+
div.dt-button-background {
|
771 |
+
position: fixed;
|
772 |
+
top: 0;
|
773 |
+
left: 0;
|
774 |
+
width: 100%;
|
775 |
+
height: 100%;
|
776 |
+
background: rgba(0, 0, 0, 0.7);
|
777 |
+
/* Fallback */
|
778 |
+
background: -ms-radial-gradient(center, ellipse farthest-corner, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
779 |
+
/* IE10 Consumer Preview */
|
780 |
+
background: -moz-radial-gradient(center, ellipse farthest-corner, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
781 |
+
/* Firefox */
|
782 |
+
background: -o-radial-gradient(center, ellipse farthest-corner, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
783 |
+
/* Opera */
|
784 |
+
background: -webkit-gradient(radial, center center, 0, center center, 497, color-stop(0, rgba(0, 0, 0, 0.3)), color-stop(1, rgba(0, 0, 0, 0.7)));
|
785 |
+
/* Webkit (Safari/Chrome 10) */
|
786 |
+
background: -webkit-radial-gradient(center, ellipse farthest-corner, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
787 |
+
/* Webkit (Chrome 11+) */
|
788 |
+
background: radial-gradient(ellipse farthest-corner at center, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
789 |
+
/* W3C Markup, IE10 Release Preview */
|
790 |
+
z-index: 2001;
|
791 |
+
}
|
792 |
+
|
793 |
+
@media screen and (max-width: 640px) {
|
794 |
+
div.dt-buttons {
|
795 |
+
float: none !important;
|
796 |
+
text-align: center;
|
797 |
+
}
|
798 |
+
}
|
799 |
+
button.dt-button.processing,
|
800 |
+
div.dt-button.processing,
|
801 |
+
a.dt-button.processing {
|
802 |
+
color: rgba(0, 0, 0, 0.2);
|
803 |
+
}
|
804 |
+
button.dt-button.processing:after,
|
805 |
+
div.dt-button.processing:after,
|
806 |
+
a.dt-button.processing:after {
|
807 |
+
position: absolute;
|
808 |
+
top: 50%;
|
809 |
+
left: 50%;
|
810 |
+
width: 16px;
|
811 |
+
height: 16px;
|
812 |
+
margin: -8px 0 0 -8px;
|
813 |
+
box-sizing: border-box;
|
814 |
+
display: block;
|
815 |
+
content: ' ';
|
816 |
+
border: 2px solid #282828;
|
817 |
+
border-radius: 50%;
|
818 |
+
border-left-color: transparent;
|
819 |
+
border-right-color: transparent;
|
820 |
+
animation: dtb-spinner 1500ms infinite linear;
|
821 |
+
-o-animation: dtb-spinner 1500ms infinite linear;
|
822 |
+
-ms-animation: dtb-spinner 1500ms infinite linear;
|
823 |
+
-webkit-animation: dtb-spinner 1500ms infinite linear;
|
824 |
+
-moz-animation: dtb-spinner 1500ms infinite linear;
|
825 |
+
}
|
826 |
+
|
827 |
+
|
828 |
+
table.DTCR_clonedTable.dataTable {
|
829 |
+
position: absolute !important;
|
830 |
+
background-color: rgba(255, 255, 255, 0.7);
|
831 |
+
z-index: 202;
|
832 |
+
}
|
833 |
+
|
834 |
+
div.DTCR_pointer {
|
835 |
+
width: 1px;
|
836 |
+
background-color: #0259C4;
|
837 |
+
z-index: 201;
|
838 |
+
}
|
839 |
+
|
840 |
+
|
841 |
+
table.DTFC_Cloned thead,
|
842 |
+
table.DTFC_Cloned tfoot {
|
843 |
+
background-color: white;
|
844 |
+
}
|
845 |
+
|
846 |
+
div.DTFC_Blocker {
|
847 |
+
background-color: white;
|
848 |
+
}
|
849 |
+
|
850 |
+
div.DTFC_LeftWrapper table.dataTable,
|
851 |
+
div.DTFC_RightWrapper table.dataTable {
|
852 |
+
margin-bottom: 0;
|
853 |
+
z-index: 2;
|
854 |
+
}
|
855 |
+
div.DTFC_LeftWrapper table.dataTable.no-footer,
|
856 |
+
div.DTFC_RightWrapper table.dataTable.no-footer {
|
857 |
+
border-bottom: none;
|
858 |
+
}
|
859 |
+
|
860 |
+
|
861 |
+
table.fixedHeader-floating {
|
862 |
+
position: fixed !important;
|
863 |
+
background-color: white;
|
864 |
+
}
|
865 |
+
|
866 |
+
table.fixedHeader-floating.no-footer {
|
867 |
+
border-bottom-width: 0;
|
868 |
+
}
|
869 |
+
|
870 |
+
table.fixedHeader-locked {
|
871 |
+
position: absolute !important;
|
872 |
+
background-color: white;
|
873 |
+
}
|
874 |
+
|
875 |
+
@media print {
|
876 |
+
table.fixedHeader-floating {
|
877 |
+
display: none;
|
878 |
+
}
|
879 |
+
}
|
880 |
+
|
881 |
+
|
882 |
+
table.dataTable th.focus,
|
883 |
+
table.dataTable td.focus {
|
884 |
+
outline: 3px solid #3366FF;
|
885 |
+
outline-offset: -1px;
|
886 |
+
}
|
887 |
+
|
888 |
+
|
889 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > td.child,
|
890 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > th.child,
|
891 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dataTables_empty {
|
892 |
+
cursor: default !important;
|
893 |
+
}
|
894 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > td.child:before,
|
895 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > th.child:before,
|
896 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dataTables_empty:before {
|
897 |
+
display: none !important;
|
898 |
+
}
|
899 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr[role="row"] > td:first-child,
|
900 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr[role="row"] > th:first-child {
|
901 |
+
position: relative;
|
902 |
+
padding-left: 30px;
|
903 |
+
cursor: pointer;
|
904 |
+
}
|
905 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr[role="row"] > td:first-child:before,
|
906 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr[role="row"] > th:first-child:before {
|
907 |
+
top: 9px;
|
908 |
+
left: 4px;
|
909 |
+
height: 14px;
|
910 |
+
width: 14px;
|
911 |
+
display: block;
|
912 |
+
position: absolute;
|
913 |
+
color: white;
|
914 |
+
border: 2px solid white;
|
915 |
+
border-radius: 14px;
|
916 |
+
box-shadow: 0 0 3px #444;
|
917 |
+
box-sizing: content-box;
|
918 |
+
text-align: center;
|
919 |
+
text-indent: 0 !important;
|
920 |
+
font-family: 'Courier New', Courier, monospace;
|
921 |
+
line-height: 14px;
|
922 |
+
content: '+';
|
923 |
+
background-color: #31b131;
|
924 |
+
}
|
925 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td:first-child:before,
|
926 |
+
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > th:first-child:before {
|
927 |
+
content: '-';
|
928 |
+
background-color: #d33333;
|
929 |
+
}
|
930 |
+
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > td:first-child,
|
931 |
+
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > th:first-child {
|
932 |
+
padding-left: 27px;
|
933 |
+
}
|
934 |
+
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > td:first-child:before,
|
935 |
+
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > th:first-child:before {
|
936 |
+
top: 5px;
|
937 |
+
left: 4px;
|
938 |
+
height: 14px;
|
939 |
+
width: 14px;
|
940 |
+
border-radius: 14px;
|
941 |
+
line-height: 14px;
|
942 |
+
text-indent: 3px;
|
943 |
+
}
|
944 |
+
table.dataTable.dtr-column > tbody > tr > td.control,
|
945 |
+
table.dataTable.dtr-column > tbody > tr > th.control {
|
946 |
+
position: relative;
|
947 |
+
cursor: pointer;
|
948 |
+
}
|
949 |
+
table.dataTable.dtr-column > tbody > tr > td.control:before,
|
950 |
+
table.dataTable.dtr-column > tbody > tr > th.control:before {
|
951 |
+
top: 50%;
|
952 |
+
left: 50%;
|
953 |
+
height: 16px;
|
954 |
+
width: 16px;
|
955 |
+
margin-top: -10px;
|
956 |
+
margin-left: -10px;
|
957 |
+
display: block;
|
958 |
+
position: absolute;
|
959 |
+
color: white;
|
960 |
+
border: 2px solid white;
|
961 |
+
border-radius: 14px;
|
962 |
+
box-shadow: 0 0 3px #444;
|
963 |
+
box-sizing: content-box;
|
964 |
+
text-align: center;
|
965 |
+
text-indent: 0 !important;
|
966 |
+
font-family: 'Courier New', Courier, monospace;
|
967 |
+
line-height: 14px;
|
968 |
+
content: '+';
|
969 |
+
background-color: #31b131;
|
970 |
+
}
|
971 |
+
table.dataTable.dtr-column > tbody > tr.parent td.control:before,
|
972 |
+
table.dataTable.dtr-column > tbody > tr.parent th.control:before {
|
973 |
+
content: '-';
|
974 |
+
background-color: #d33333;
|
975 |
+
}
|
976 |
+
table.dataTable > tbody > tr.child {
|
977 |
+
padding: 0.5em 1em;
|
978 |
+
}
|
979 |
+
table.dataTable > tbody > tr.child:hover {
|
980 |
+
background: transparent !important;
|
981 |
+
}
|
982 |
+
table.dataTable > tbody > tr.child ul.dtr-details {
|
983 |
+
display: inline-block;
|
984 |
+
list-style-type: none;
|
985 |
+
margin: 0;
|
986 |
+
padding: 0;
|
987 |
+
}
|
988 |
+
table.dataTable > tbody > tr.child ul.dtr-details > li {
|
989 |
+
border-bottom: 1px solid #efefef;
|
990 |
+
padding: 0.5em 0;
|
991 |
+
}
|
992 |
+
table.dataTable > tbody > tr.child ul.dtr-details > li:first-child {
|
993 |
+
padding-top: 0;
|
994 |
+
}
|
995 |
+
table.dataTable > tbody > tr.child ul.dtr-details > li:last-child {
|
996 |
+
border-bottom: none;
|
997 |
+
}
|
998 |
+
table.dataTable > tbody > tr.child span.dtr-title {
|
999 |
+
display: inline-block;
|
1000 |
+
min-width: 75px;
|
1001 |
+
font-weight: bold;
|
1002 |
+
}
|
1003 |
+
|
1004 |
+
div.dtr-modal {
|
1005 |
+
position: fixed;
|
1006 |
+
box-sizing: border-box;
|
1007 |
+
top: 0;
|
1008 |
+
left: 0;
|
1009 |
+
height: 100%;
|
1010 |
+
width: 100%;
|
1011 |
+
z-index: 100;
|
1012 |
+
padding: 10em 1em;
|
1013 |
+
}
|
1014 |
+
div.dtr-modal div.dtr-modal-display {
|
1015 |
+
position: absolute;
|
1016 |
+
top: 0;
|
1017 |
+
left: 0;
|
1018 |
+
bottom: 0;
|
1019 |
+
right: 0;
|
1020 |
+
width: 50%;
|
1021 |
+
height: 50%;
|
1022 |
+
overflow: auto;
|
1023 |
+
margin: auto;
|
1024 |
+
z-index: 102;
|
1025 |
+
overflow: auto;
|
1026 |
+
background-color: #f5f5f7;
|
1027 |
+
border: 1px solid black;
|
1028 |
+
border-radius: 0.5em;
|
1029 |
+
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
|
1030 |
+
}
|
1031 |
+
div.dtr-modal div.dtr-modal-content {
|
1032 |
+
position: relative;
|
1033 |
+
padding: 1em;
|
1034 |
+
}
|
1035 |
+
div.dtr-modal div.dtr-modal-close {
|
1036 |
+
position: absolute;
|
1037 |
+
top: 6px;
|
1038 |
+
right: 6px;
|
1039 |
+
width: 22px;
|
1040 |
+
height: 22px;
|
1041 |
+
border: 1px solid #eaeaea;
|
1042 |
+
background-color: #f9f9f9;
|
1043 |
+
text-align: center;
|
1044 |
+
border-radius: 3px;
|
1045 |
+
cursor: pointer;
|
1046 |
+
z-index: 12;
|
1047 |
+
}
|
1048 |
+
div.dtr-modal div.dtr-modal-close:hover {
|
1049 |
+
background-color: #eaeaea;
|
1050 |
+
}
|
1051 |
+
div.dtr-modal div.dtr-modal-background {
|
1052 |
+
position: fixed;
|
1053 |
+
top: 0;
|
1054 |
+
left: 0;
|
1055 |
+
right: 0;
|
1056 |
+
bottom: 0;
|
1057 |
+
z-index: 101;
|
1058 |
+
background: rgba(0, 0, 0, 0.6);
|
1059 |
+
}
|
1060 |
+
|
1061 |
+
@media screen and (max-width: 767px) {
|
1062 |
+
div.dtr-modal div.dtr-modal-display {
|
1063 |
+
width: 95%;
|
1064 |
+
}
|
1065 |
+
}
|
1066 |
+
|
1067 |
+
|
1068 |
+
table.dt-rowReorder-float {
|
1069 |
+
position: absolute !important;
|
1070 |
+
opacity: 0.8;
|
1071 |
+
table-layout: fixed;
|
1072 |
+
outline: 2px solid #888;
|
1073 |
+
outline-offset: -2px;
|
1074 |
+
z-index: 2001;
|
1075 |
+
}
|
1076 |
+
|
1077 |
+
tr.dt-rowReorder-moving {
|
1078 |
+
outline: 2px solid #555;
|
1079 |
+
outline-offset: -2px;
|
1080 |
+
}
|
1081 |
+
|
1082 |
+
body.dt-rowReorder-noOverflow {
|
1083 |
+
overflow-x: hidden;
|
1084 |
+
}
|
1085 |
+
|
1086 |
+
table.dataTable td.reorder {
|
1087 |
+
text-align: center;
|
1088 |
+
cursor: move;
|
1089 |
+
}
|
1090 |
+
|
1091 |
+
|
1092 |
+
div.DTS {
|
1093 |
+
display: block !important;
|
1094 |
+
}
|
1095 |
+
div.DTS tbody th,
|
1096 |
+
div.DTS tbody td {
|
1097 |
+
white-space: nowrap;
|
1098 |
+
}
|
1099 |
+
div.DTS div.DTS_Loading {
|
1100 |
+
z-index: 1;
|
1101 |
+
}
|
1102 |
+
div.DTS div.dataTables_scrollBody {
|
1103 |
+
background: repeating-linear-gradient(45deg, #edeeff, #edeeff 10px, white 10px, white 20px);
|
1104 |
+
}
|
1105 |
+
div.DTS div.dataTables_scrollBody table {
|
1106 |
+
z-index: 2;
|
1107 |
+
}
|
1108 |
+
div.DTS div.dataTables_paginate,
|
1109 |
+
div.DTS div.dataTables_length {
|
1110 |
+
display: none;
|
1111 |
+
}
|
1112 |
+
|
1113 |
+
|
1114 |
+
table.dataTable tbody > tr.selected,
|
1115 |
+
table.dataTable tbody > tr > .selected {
|
1116 |
+
background-color: #B0BED9;
|
1117 |
+
}
|
1118 |
+
table.dataTable.stripe tbody > tr.odd.selected,
|
1119 |
+
table.dataTable.stripe tbody > tr.odd > .selected, table.dataTable.display tbody > tr.odd.selected,
|
1120 |
+
table.dataTable.display tbody > tr.odd > .selected {
|
1121 |
+
background-color: #acbad4;
|
1122 |
+
}
|
1123 |
+
table.dataTable.hover tbody > tr.selected:hover,
|
1124 |
+
table.dataTable.hover tbody > tr > .selected:hover, table.dataTable.display tbody > tr.selected:hover,
|
1125 |
+
table.dataTable.display tbody > tr > .selected:hover {
|
1126 |
+
background-color: #aab7d1;
|
1127 |
+
}
|
1128 |
+
table.dataTable.order-column tbody > tr.selected > .sorting_1,
|
1129 |
+
table.dataTable.order-column tbody > tr.selected > .sorting_2,
|
1130 |
+
table.dataTable.order-column tbody > tr.selected > .sorting_3,
|
1131 |
+
table.dataTable.order-column tbody > tr > .selected, table.dataTable.display tbody > tr.selected > .sorting_1,
|
1132 |
+
table.dataTable.display tbody > tr.selected > .sorting_2,
|
1133 |
+
table.dataTable.display tbody > tr.selected > .sorting_3,
|
1134 |
+
table.dataTable.display tbody > tr > .selected {
|
1135 |
+
background-color: #acbad5;
|
1136 |
+
}
|
1137 |
+
table.dataTable.display tbody > tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_1 {
|
1138 |
+
background-color: #a6b4cd;
|
1139 |
+
}
|
1140 |
+
table.dataTable.display tbody > tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_2 {
|
1141 |
+
background-color: #a8b5cf;
|
1142 |
+
}
|
1143 |
+
table.dataTable.display tbody > tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_3 {
|
1144 |
+
background-color: #a9b7d1;
|
1145 |
+
}
|
1146 |
+
table.dataTable.display tbody > tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_1 {
|
1147 |
+
background-color: #acbad5;
|
1148 |
+
}
|
1149 |
+
table.dataTable.display tbody > tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_2 {
|
1150 |
+
background-color: #aebcd6;
|
1151 |
+
}
|
1152 |
+
table.dataTable.display tbody > tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_3 {
|
1153 |
+
background-color: #afbdd8;
|
1154 |
+
}
|
1155 |
+
table.dataTable.display tbody > tr.odd > .selected, table.dataTable.order-column.stripe tbody > tr.odd > .selected {
|
1156 |
+
background-color: #a6b4cd;
|
1157 |
+
}
|
1158 |
+
table.dataTable.display tbody > tr.even > .selected, table.dataTable.order-column.stripe tbody > tr.even > .selected {
|
1159 |
+
background-color: #acbad5;
|
1160 |
+
}
|
1161 |
+
table.dataTable.display tbody > tr.selected:hover > .sorting_1, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_1 {
|
1162 |
+
background-color: #a2aec7;
|
1163 |
+
}
|
1164 |
+
table.dataTable.display tbody > tr.selected:hover > .sorting_2, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_2 {
|
1165 |
+
background-color: #a3b0c9;
|
1166 |
+
}
|
1167 |
+
table.dataTable.display tbody > tr.selected:hover > .sorting_3, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_3 {
|
1168 |
+
background-color: #a5b2cb;
|
1169 |
+
}
|
1170 |
+
table.dataTable.display tbody > tr:hover > .selected,
|
1171 |
+
table.dataTable.display tbody > tr > .selected:hover, table.dataTable.order-column.hover tbody > tr:hover > .selected,
|
1172 |
+
table.dataTable.order-column.hover tbody > tr > .selected:hover {
|
1173 |
+
background-color: #a2aec7;
|
1174 |
+
}
|
1175 |
+
table.dataTable tbody td.select-checkbox,
|
1176 |
+
table.dataTable tbody th.select-checkbox {
|
1177 |
+
position: relative;
|
1178 |
+
}
|
1179 |
+
table.dataTable tbody td.select-checkbox:before, table.dataTable tbody td.select-checkbox:after,
|
1180 |
+
table.dataTable tbody th.select-checkbox:before,
|
1181 |
+
table.dataTable tbody th.select-checkbox:after {
|
1182 |
+
display: block;
|
1183 |
+
position: absolute;
|
1184 |
+
top: 1.2em;
|
1185 |
+
left: 50%;
|
1186 |
+
width: 12px;
|
1187 |
+
height: 12px;
|
1188 |
+
box-sizing: border-box;
|
1189 |
+
}
|
1190 |
+
table.dataTable tbody td.select-checkbox:before,
|
1191 |
+
table.dataTable tbody th.select-checkbox:before {
|
1192 |
+
content: ' ';
|
1193 |
+
margin-top: -6px;
|
1194 |
+
margin-left: -6px;
|
1195 |
+
border: 1px solid black;
|
1196 |
+
border-radius: 3px;
|
1197 |
+
}
|
1198 |
+
table.dataTable tr.selected td.select-checkbox:after,
|
1199 |
+
table.dataTable tr.selected th.select-checkbox:after {
|
1200 |
+
content: '\2714';
|
1201 |
+
margin-top: -11px;
|
1202 |
+
margin-left: -4px;
|
1203 |
+
text-align: center;
|
1204 |
+
text-shadow: 1px 1px #B0BED9, -1px -1px #B0BED9, 1px -1px #B0BED9, -1px 1px #B0BED9;
|
1205 |
+
}
|
1206 |
+
|
1207 |
+
div.dataTables_wrapper span.select-info,
|
1208 |
+
div.dataTables_wrapper span.select-item {
|
1209 |
+
margin-left: 0.5em;
|
1210 |
+
}
|
1211 |
+
|
1212 |
+
@media screen and (max-width: 640px) {
|
1213 |
+
div.dataTables_wrapper span.select-info,
|
1214 |
+
div.dataTables_wrapper span.select-item {
|
1215 |
+
margin-left: 0;
|
1216 |
+
display: block;
|
1217 |
+
}
|
1218 |
+
}
|
1219 |
+
|
1220 |
+
|
common/vendor/datatables/{media/js/jquery.dataTables.js → datatables.js}
RENAMED
@@ -1,15 +1,27 @@
|
|
1 |
-
|
2 |
-
*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
*/
|
4 |
|
5 |
/**
|
6 |
* @summary DataTables
|
7 |
* @description Paginate, search and order HTML tables
|
8 |
-
* @version 1.10.
|
9 |
* @file jquery.dataTables.js
|
10 |
-
* @author SpryMedia Ltd
|
11 |
-
* @contact www.
|
12 |
-
* @copyright Copyright 2008-
|
13 |
*
|
14 |
* This source file is free software, available under the following license:
|
15 |
* MIT license - http://datatables.net/license
|
@@ -279,7 +291,7 @@
|
|
279 |
* "bPaginate": false
|
280 |
* } );
|
281 |
*
|
282 |
-
* $(window).
|
283 |
* oTable.fnAdjustColumnSizing();
|
284 |
* } );
|
285 |
* } );
|
@@ -1023,8 +1035,7 @@
|
|
1023 |
[ "iCookieDuration", "iStateDuration" ], // backwards compat
|
1024 |
[ "oSearch", "oPreviousSearch" ],
|
1025 |
[ "aoSearchCols", "aoPreSearchCols" ],
|
1026 |
-
[ "iDisplayLength", "_iDisplayLength" ]
|
1027 |
-
[ "bJQueryUI", "bJUI" ]
|
1028 |
] );
|
1029 |
_fnMap( oSettings.oScroll, oInit, [
|
1030 |
[ "sScrollX", "sX" ],
|
@@ -1054,31 +1065,7 @@
|
|
1054 |
|
1055 |
var oClasses = oSettings.oClasses;
|
1056 |
|
1057 |
-
|
1058 |
-
if ( oInit.bJQueryUI )
|
1059 |
-
{
|
1060 |
-
/* Use the JUI classes object for display. You could clone the oStdClasses object if
|
1061 |
-
* you want to have multiple tables with multiple independent classes
|
1062 |
-
*/
|
1063 |
-
$.extend( oClasses, DataTable.ext.oJUIClasses, oInit.oClasses );
|
1064 |
-
|
1065 |
-
if ( oInit.sDom === defaults.sDom && defaults.sDom === "lfrtip" )
|
1066 |
-
{
|
1067 |
-
/* Set the DOM to use a layout suitable for jQuery UI's theming */
|
1068 |
-
oSettings.sDom = '<"H"lfr>t<"F"ip>';
|
1069 |
-
}
|
1070 |
-
|
1071 |
-
if ( ! oSettings.renderer ) {
|
1072 |
-
oSettings.renderer = 'jqueryui';
|
1073 |
-
}
|
1074 |
-
else if ( $.isPlainObject( oSettings.renderer ) && ! oSettings.renderer.header ) {
|
1075 |
-
oSettings.renderer.header = 'jqueryui';
|
1076 |
-
}
|
1077 |
-
}
|
1078 |
-
else
|
1079 |
-
{
|
1080 |
-
$.extend( oClasses, DataTable.ext.classes, oInit.oClasses );
|
1081 |
-
}
|
1082 |
$this.addClass( oClasses.sTable );
|
1083 |
|
1084 |
|
@@ -1101,7 +1088,7 @@
|
|
1101 |
var oLanguage = oSettings.oLanguage;
|
1102 |
$.extend( true, oLanguage, oInit.oLanguage );
|
1103 |
|
1104 |
-
if ( oLanguage.sUrl
|
1105 |
{
|
1106 |
/* Get the language definitions from a file - because this Ajax call makes the language
|
1107 |
* get async to the remainder of this function we use bInitHandedOff to indicate that
|
@@ -1213,131 +1200,125 @@
|
|
1213 |
}
|
1214 |
|
1215 |
var features = oSettings.oFeatures;
|
|
|
|
|
|
|
|
|
|
|
1216 |
|
1217 |
-
|
1218 |
-
|
1219 |
-
|
1220 |
-
|
1221 |
-
|
1222 |
-
|
1223 |
-
|
|
|
1224 |
|
|
|
|
|
|
|
|
|
1225 |
|
1226 |
-
|
1227 |
-
|
1228 |
-
|
1229 |
-
|
|
|
1230 |
|
1231 |
-
|
1232 |
-
|
1233 |
-
|
1234 |
-
{
|
1235 |
-
var sorting = oSettings.aaSorting;
|
1236 |
-
for ( i=0, iLen=sorting.length ; i<iLen ; i++ )
|
1237 |
-
{
|
1238 |
-
sorting[i][1] = oSettings.aoColumns[ i ].asSorting[0];
|
1239 |
-
}
|
1240 |
-
}
|
1241 |
|
1242 |
-
|
1243 |
-
|
1244 |
-
|
1245 |
-
|
|
|
1246 |
|
1247 |
-
if ( features.bSort )
|
1248 |
-
{
|
1249 |
_fnCallbackReg( oSettings, 'aoDrawCallback', function () {
|
1250 |
-
if ( oSettings.bSorted ) {
|
1251 |
-
|
1252 |
-
|
|
|
1253 |
|
1254 |
-
$.each( aSort, function (i, val) {
|
1255 |
-
sortedColumns[ val.src ] = val.dir;
|
1256 |
-
} );
|
1257 |
|
1258 |
-
|
1259 |
-
|
1260 |
-
|
|
|
|
|
|
|
|
|
|
|
1261 |
} );
|
1262 |
-
}
|
1263 |
|
1264 |
-
|
1265 |
-
if (
|
1266 |
-
|
1267 |
}
|
1268 |
-
|
1269 |
|
|
|
|
|
|
|
|
|
|
|
1270 |
|
1271 |
-
|
1272 |
-
|
1273 |
-
|
1274 |
-
|
|
|
|
|
1275 |
|
1276 |
-
|
1277 |
-
|
1278 |
-
|
1279 |
-
|
|
|
|
|
|
|
1280 |
|
1281 |
-
|
1282 |
-
|
1283 |
-
|
1284 |
-
|
1285 |
-
|
1286 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1287 |
|
1288 |
-
|
1289 |
-
|
1290 |
-
{
|
1291 |
-
tbody = $('<tbody/>').appendTo(this);
|
1292 |
-
}
|
1293 |
-
oSettings.nTBody = tbody[0];
|
1294 |
|
1295 |
-
|
1296 |
-
|
1297 |
-
{
|
1298 |
-
// If we are a scrolling table, and no footer has been given, then we need to create
|
1299 |
-
// a tfoot element for the caption element to be appended to
|
1300 |
-
tfoot = $('<tfoot/>').appendTo(this);
|
1301 |
-
}
|
1302 |
|
1303 |
-
|
1304 |
-
|
1305 |
-
|
1306 |
-
|
1307 |
-
|
1308 |
-
|
1309 |
-
}
|
1310 |
|
1311 |
-
/*
|
1312 |
-
if ( oInit.
|
1313 |
{
|
1314 |
-
|
1315 |
-
|
1316 |
-
|
1317 |
-
}
|
1318 |
}
|
1319 |
-
else
|
1320 |
-
|
1321 |
-
/* Grab the data from the page - only do this when deferred loading or no Ajax
|
1322 |
-
* source since there is no point in reading the DOM data if we are then going
|
1323 |
-
* to replace it with Ajax data
|
1324 |
-
*/
|
1325 |
-
_fnAddTr( oSettings, $(oSettings.nTBody).children('tr') );
|
1326 |
}
|
1327 |
|
1328 |
-
/* Copy the data index array */
|
1329 |
-
oSettings.aiDisplay = oSettings.aiDisplayMaster.slice();
|
1330 |
-
|
1331 |
-
/* Initialisation complete - table can be drawn */
|
1332 |
-
oSettings.bInitialised = true;
|
1333 |
-
|
1334 |
-
/* Check if we need to initialise the table (it might not have been handed off to the
|
1335 |
-
* language processor)
|
1336 |
-
*/
|
1337 |
-
if ( bInitHandedOff === false )
|
1338 |
-
{
|
1339 |
-
_fnInitialise( oSettings );
|
1340 |
-
}
|
1341 |
} );
|
1342 |
_that = null;
|
1343 |
return this;
|
@@ -1368,8 +1349,10 @@
|
|
1368 |
var _re_dic = {};
|
1369 |
var _re_new_lines = /[\r\n]/g;
|
1370 |
var _re_html = /<.*?>/g;
|
1371 |
-
|
1372 |
-
|
|
|
|
|
1373 |
|
1374 |
// Escape regular expression special characters
|
1375 |
var _re_escape_regex = new RegExp( '(\\' + [ '/', '.', '*', '+', '?', '|', '(', ')', '[', ']', '{', '}', '\\', '$', '^', '-' ].join('|\\') + ')', 'g' );
|
@@ -1544,6 +1527,35 @@
|
|
1544 |
};
|
1545 |
|
1546 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1547 |
/**
|
1548 |
* Find the unique elements in a source array.
|
1549 |
*
|
@@ -1553,6 +1565,10 @@
|
|
1553 |
*/
|
1554 |
var _unique = function ( src )
|
1555 |
{
|
|
|
|
|
|
|
|
|
1556 |
// A faster unique method is to use object keys to identify used values,
|
1557 |
// but this doesn't work with arrays or objects, which we must also
|
1558 |
// consider. See jsperf.com/compare-array-unique-versions/4 for more
|
@@ -1826,7 +1842,7 @@
|
|
1826 |
|
1827 |
// orderData can be given as an integer
|
1828 |
var dataSort = init.aDataSort;
|
1829 |
-
if ( dataSort && ! $.isArray( dataSort ) ) {
|
1830 |
init.aDataSort = [ dataSort ];
|
1831 |
}
|
1832 |
}
|
@@ -1851,7 +1867,7 @@
|
|
1851 |
.css( {
|
1852 |
position: 'fixed',
|
1853 |
top: 0,
|
1854 |
-
left:
|
1855 |
height: 1,
|
1856 |
width: 1,
|
1857 |
overflow: 'hidden'
|
@@ -2028,6 +2044,9 @@
|
|
2028 |
{
|
2029 |
oOptions.sClass = oOptions.className;
|
2030 |
}
|
|
|
|
|
|
|
2031 |
|
2032 |
$.extend( oCol, oOptions );
|
2033 |
_fnMap( oCol, oOptions, "sWidth", "sWidthOrig" );
|
@@ -2544,7 +2563,7 @@
|
|
2544 |
function _fnSplitObjNotation( str )
|
2545 |
{
|
2546 |
return $.map( str.match(/(\\.|[^\.])+/g) || [''], function ( s ) {
|
2547 |
-
return s.replace(
|
2548 |
} );
|
2549 |
}
|
2550 |
|
@@ -4202,13 +4221,13 @@
|
|
4202 |
var jqFilter = $('input', filter)
|
4203 |
.val( previousSearch.sSearch )
|
4204 |
.attr( 'placeholder', language.sSearchPlaceholder )
|
4205 |
-
.
|
4206 |
'keyup.DT search.DT input.DT paste.DT cut.DT',
|
4207 |
searchDelay ?
|
4208 |
_fnThrottle( searchFn, searchDelay ) :
|
4209 |
searchFn
|
4210 |
)
|
4211 |
-
.
|
4212 |
/* Prevent form submission */
|
4213 |
if ( e.keyCode == 13 ) {
|
4214 |
return false;
|
@@ -4338,16 +4357,19 @@
|
|
4338 |
}
|
4339 |
|
4340 |
var data;
|
|
|
4341 |
var display = settings.aiDisplay;
|
4342 |
var rpSearch = _fnFilterCreateSearch( searchStr, regex, smart, caseInsensitive );
|
4343 |
|
4344 |
-
for ( var i=
|
4345 |
data = settings.aoData[ display[i] ]._aFilterData[ colIdx ];
|
4346 |
|
4347 |
-
if (
|
4348 |
-
|
4349 |
}
|
4350 |
}
|
|
|
|
|
4351 |
}
|
4352 |
|
4353 |
|
@@ -4367,6 +4389,7 @@
|
|
4367 |
var prevSearch = settings.oPreviousSearch.sSearch;
|
4368 |
var displayMaster = settings.aiDisplayMaster;
|
4369 |
var display, invalidated, i;
|
|
|
4370 |
|
4371 |
// Need to take account of custom filtering functions - always filter
|
4372 |
if ( DataTable.ext.search.length !== 0 ) {
|
@@ -4395,11 +4418,13 @@
|
|
4395 |
// Search the display array
|
4396 |
display = settings.aiDisplay;
|
4397 |
|
4398 |
-
for ( i=
|
4399 |
-
if (
|
4400 |
-
|
4401 |
}
|
4402 |
}
|
|
|
|
|
4403 |
}
|
4404 |
}
|
4405 |
|
@@ -4796,7 +4821,12 @@
|
|
4796 |
} );
|
4797 |
|
4798 |
for ( var i=0, ien=lengths.length ; i<ien ; i++ ) {
|
4799 |
-
select[0][ i ] = new Option(
|
|
|
|
|
|
|
|
|
|
|
4800 |
}
|
4801 |
|
4802 |
var div = $('<div><label/></div>').addClass( classes.sLength );
|
@@ -4812,13 +4842,13 @@
|
|
4812 |
// reference is broken by the use of outerHTML
|
4813 |
$('select', div)
|
4814 |
.val( settings._iDisplayLength )
|
4815 |
-
.
|
4816 |
_fnLengthChange( settings, $(this).val() );
|
4817 |
_fnDraw( settings );
|
4818 |
} );
|
4819 |
|
4820 |
// Update node value whenever anything changes the table's length
|
4821 |
-
$(settings.nTable).
|
4822 |
if ( settings === s ) {
|
4823 |
$('select', div).val( len );
|
4824 |
}
|
@@ -5683,7 +5713,7 @@
|
|
5683 |
|
5684 |
if ( (tableWidthAttr || scrollX) && ! oSettings._reszEvt ) {
|
5685 |
var bindResize = function () {
|
5686 |
-
$(window).
|
5687 |
_fnAdjustColumnSizing( oSettings );
|
5688 |
} ) );
|
5689 |
};
|
@@ -6294,86 +6324,102 @@
|
|
6294 |
* Attempt to load a saved table state
|
6295 |
* @param {object} oSettings dataTables settings object
|
6296 |
* @param {object} oInit DataTables init object so we can override settings
|
|
|
6297 |
* @memberof DataTable#oApi
|
6298 |
*/
|
6299 |
-
function _fnLoadState ( settings, oInit )
|
6300 |
{
|
6301 |
var i, ien;
|
6302 |
var columns = settings.aoColumns;
|
|
|
|
|
|
|
|
|
|
|
6303 |
|
6304 |
-
|
6305 |
-
|
6306 |
-
|
6307 |
-
|
6308 |
-
|
6309 |
-
|
6310 |
-
|
6311 |
-
}
|
6312 |
|
6313 |
-
|
6314 |
-
|
6315 |
-
|
6316 |
-
|
6317 |
-
|
6318 |
-
|
6319 |
-
}
|
6320 |
|
6321 |
-
|
6322 |
-
|
6323 |
-
|
6324 |
-
|
6325 |
-
|
6326 |
|
6327 |
-
|
6328 |
-
|
6329 |
-
return;
|
6330 |
-
}
|
6331 |
|
6332 |
-
|
6333 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
6334 |
|
6335 |
-
|
6336 |
-
|
6337 |
-
|
6338 |
-
|
6339 |
-
|
6340 |
-
|
6341 |
-
|
6342 |
-
|
6343 |
-
|
|
|
6344 |
|
6345 |
-
|
6346 |
-
|
6347 |
-
|
6348 |
-
|
6349 |
-
settings.aaSorting.push( col[0] >= columns.length ?
|
6350 |
-
[ 0, col[1] ] :
|
6351 |
-
col
|
6352 |
-
);
|
6353 |
-
} );
|
6354 |
-
}
|
6355 |
|
6356 |
-
|
6357 |
-
|
6358 |
-
|
6359 |
-
|
|
|
6360 |
|
6361 |
-
|
6362 |
-
|
6363 |
-
|
|
|
6364 |
|
6365 |
-
|
6366 |
-
|
6367 |
-
|
|
|
|
|
6368 |
}
|
6369 |
|
6370 |
-
|
6371 |
-
|
6372 |
-
|
6373 |
-
|
|
|
|
|
|
|
6374 |
}
|
6375 |
|
6376 |
-
|
|
|
|
|
|
|
|
|
|
|
6377 |
}
|
6378 |
|
6379 |
|
@@ -6526,17 +6572,17 @@
|
|
6526 |
function _fnBindAction( n, oData, fn )
|
6527 |
{
|
6528 |
$(n)
|
6529 |
-
.
|
6530 |
n.blur(); // Remove focus outline for mouse users
|
6531 |
fn(e);
|
6532 |
} )
|
6533 |
-
.
|
6534 |
if ( e.which === 13 ) {
|
6535 |
e.preventDefault();
|
6536 |
fn(e);
|
6537 |
}
|
6538 |
} )
|
6539 |
-
.
|
6540 |
/* Take the brutal approach to cancelling text selection */
|
6541 |
return false;
|
6542 |
} );
|
@@ -7091,6 +7137,11 @@
|
|
7091 |
shift: __arrayProto.shift,
|
7092 |
|
7093 |
|
|
|
|
|
|
|
|
|
|
|
7094 |
sort: __arrayProto.sort, // ? name - order?
|
7095 |
|
7096 |
|
@@ -7664,7 +7715,8 @@
|
|
7664 |
}
|
7665 |
|
7666 |
for ( i=0, ien=selector.length ; i<ien ; i++ ) {
|
7667 |
-
|
|
|
7668 |
selector[i].split(',') :
|
7669 |
[ selector[i] ];
|
7670 |
|
@@ -7804,6 +7856,7 @@
|
|
7804 |
|
7805 |
var __row_selector = function ( settings, selector, opts )
|
7806 |
{
|
|
|
7807 |
var run = function ( sel ) {
|
7808 |
var selInt = _intVal( sel );
|
7809 |
var i, ien;
|
@@ -7815,13 +7868,15 @@
|
|
7815 |
return [ selInt ];
|
7816 |
}
|
7817 |
|
7818 |
-
|
|
|
|
|
7819 |
|
7820 |
if ( selInt !== null && $.inArray( selInt, rows ) !== -1 ) {
|
7821 |
// Selector - integer
|
7822 |
return [ selInt ];
|
7823 |
}
|
7824 |
-
else if (
|
7825 |
// Selector - none
|
7826 |
return rows;
|
7827 |
}
|
@@ -7993,6 +8048,11 @@
|
|
7993 |
_fnDeleteIndex( settings.aiDisplay, row );
|
7994 |
_fnDeleteIndex( that[ thatIdx ], row, false ); // maintain local indexes
|
7995 |
|
|
|
|
|
|
|
|
|
|
|
7996 |
// Check for an 'overflow' they case for displaying the table
|
7997 |
_fnLengthOverflow( settings );
|
7998 |
|
@@ -8134,7 +8194,7 @@
|
|
8134 |
addRow( data, klass );
|
8135 |
|
8136 |
if ( row._details ) {
|
8137 |
-
row._details.
|
8138 |
}
|
8139 |
|
8140 |
row._details = $(rows);
|
@@ -8335,7 +8395,7 @@
|
|
8335 |
// can be an array of these items, comma separated list, or an array of comma
|
8336 |
// separated lists
|
8337 |
|
8338 |
-
var __re_column_selector = /^(
|
8339 |
|
8340 |
|
8341 |
// r1 and r2 are redundant - but it means that the parameters match for the
|
@@ -9082,6 +9142,10 @@
|
|
9082 |
var t = $(table).get(0);
|
9083 |
var is = false;
|
9084 |
|
|
|
|
|
|
|
|
|
9085 |
$.each( DataTable.settings, function (i, o) {
|
9086 |
var head = o.nScrollHead ? $('table', o.nScrollHead)[0] : null;
|
9087 |
var foot = o.nScrollFoot ? $('table', o.nScrollFoot)[0] : null;
|
@@ -9170,9 +9234,11 @@
|
|
9170 |
var args = Array.prototype.slice.call(arguments);
|
9171 |
|
9172 |
// Add the `dt` namespace automatically if it isn't already present
|
9173 |
-
|
9174 |
-
|
9175 |
-
|
|
|
|
|
9176 |
|
9177 |
var inst = $( this.tables().nodes() );
|
9178 |
inst[key].apply( inst, args );
|
@@ -9237,8 +9303,8 @@
|
|
9237 |
// Blitz all `DT` namespaced events (these are internal events, the
|
9238 |
// lowercase, `dt` events are user subscribed and they are responsible
|
9239 |
// for removing them
|
9240 |
-
jqWrapper.
|
9241 |
-
$(window).
|
9242 |
|
9243 |
// When scrolling we had to break the table up - restore it
|
9244 |
if ( table != thead.parentNode ) {
|
@@ -9261,15 +9327,6 @@
|
|
9261 |
classes.sSortableAsc+' '+classes.sSortableDesc+' '+classes.sSortableNone
|
9262 |
);
|
9263 |
|
9264 |
-
if ( settings.bJUI ) {
|
9265 |
-
$('th span.'+classes.sSortIcon+ ', td span.'+classes.sSortIcon, thead).detach();
|
9266 |
-
$('th, td', thead).each( function () {
|
9267 |
-
var wrapper = $('div.'+classes.sSortJUIWrapper, this);
|
9268 |
-
$(this).append( wrapper.contents() );
|
9269 |
-
wrapper.detach();
|
9270 |
-
} );
|
9271 |
-
}
|
9272 |
-
|
9273 |
// Add the TR elements back into the table in their original order
|
9274 |
jqTbody.children().detach();
|
9275 |
jqTbody.append( rows );
|
@@ -9368,7 +9425,7 @@
|
|
9368 |
* @type string
|
9369 |
* @default Version number
|
9370 |
*/
|
9371 |
-
DataTable.version = "1.10.
|
9372 |
|
9373 |
/**
|
9374 |
* Private data store, containing all of the settings objects that are
|
@@ -10297,26 +10354,6 @@
|
|
10297 |
"bInfo": true,
|
10298 |
|
10299 |
|
10300 |
-
/**
|
10301 |
-
* Enable jQuery UI ThemeRoller support (required as ThemeRoller requires some
|
10302 |
-
* slightly different and additional mark-up from what DataTables has
|
10303 |
-
* traditionally used).
|
10304 |
-
* @type boolean
|
10305 |
-
* @default false
|
10306 |
-
*
|
10307 |
-
* @dtopt Features
|
10308 |
-
* @name DataTable.defaults.jQueryUI
|
10309 |
-
*
|
10310 |
-
* @example
|
10311 |
-
* $(document).ready( function() {
|
10312 |
-
* $('#example').dataTable( {
|
10313 |
-
* "jQueryUI": true
|
10314 |
-
* } );
|
10315 |
-
* } );
|
10316 |
-
*/
|
10317 |
-
"bJQueryUI": false,
|
10318 |
-
|
10319 |
-
|
10320 |
/**
|
10321 |
* Allows the end user to select the size of a formatted page from a select
|
10322 |
* menu (sizes are 10, 25, 50 and 100). Requires pagination (`paginate`).
|
@@ -10876,6 +10913,8 @@
|
|
10876 |
* @type function
|
10877 |
* @member
|
10878 |
* @param {object} settings DataTables settings object
|
|
|
|
|
10879 |
* @return {object} The DataTables state object to be loaded
|
10880 |
*
|
10881 |
* @dtopt Callbacks
|
@@ -10885,21 +10924,14 @@
|
|
10885 |
* $(document).ready( function() {
|
10886 |
* $('#example').dataTable( {
|
10887 |
* "stateSave": true,
|
10888 |
-
* "stateLoadCallback": function (settings) {
|
10889 |
-
* var o;
|
10890 |
-
*
|
10891 |
-
* // Send an Ajax request to the server to get the data. Note that
|
10892 |
-
* // this is a synchronous request.
|
10893 |
* $.ajax( {
|
10894 |
* "url": "/state_load",
|
10895 |
-
* "async": false,
|
10896 |
* "dataType": "json",
|
10897 |
* "success": function (json) {
|
10898 |
-
*
|
10899 |
* }
|
10900 |
* } );
|
10901 |
-
*
|
10902 |
-
* return o;
|
10903 |
* }
|
10904 |
* } );
|
10905 |
* } );
|
@@ -11838,14 +11870,15 @@
|
|
11838 |
|
11839 |
|
11840 |
/**
|
11841 |
-
* DataTables features
|
11842 |
* display for pagination control:
|
11843 |
*
|
|
|
11844 |
* * `simple` - 'Previous' and 'Next' buttons only
|
11845 |
* * 'simple_numbers` - 'Previous' and 'Next' buttons, plus page numbers
|
11846 |
* * `full` - 'First', 'Previous', 'Next' and 'Last' buttons
|
11847 |
-
* * `full_numbers` - 'First', 'Previous', 'Next' and 'Last' buttons, plus
|
11848 |
-
*
|
11849 |
*
|
11850 |
* Further methods can be added using {@link DataTable.ext.oPagination}.
|
11851 |
* @type string
|
@@ -13601,14 +13634,6 @@
|
|
13601 |
*/
|
13602 |
"_iRecordsDisplay": 0,
|
13603 |
|
13604 |
-
/**
|
13605 |
-
* Flag to indicate if jQuery UI marking and classes should be used.
|
13606 |
-
* Note that this parameter will be set by the initialisation routine. To
|
13607 |
-
* set a default use {@link DataTable.defaults}.
|
13608 |
-
* @type boolean
|
13609 |
-
*/
|
13610 |
-
"bJUI": null,
|
13611 |
-
|
13612 |
/**
|
13613 |
* The classes to use for the table
|
13614 |
* @type object
|
@@ -13822,7 +13847,7 @@
|
|
13822 |
*
|
13823 |
* @type string
|
13824 |
*/
|
13825 |
-
|
13826 |
|
13827 |
|
13828 |
/**
|
@@ -14386,59 +14411,6 @@
|
|
14386 |
} );
|
14387 |
|
14388 |
|
14389 |
-
(function() {
|
14390 |
-
|
14391 |
-
// Reused strings for better compression. Closure compiler appears to have a
|
14392 |
-
// weird edge case where it is trying to expand strings rather than use the
|
14393 |
-
// variable version. This results in about 200 bytes being added, for very
|
14394 |
-
// little preference benefit since it this run on script load only.
|
14395 |
-
var _empty = '';
|
14396 |
-
_empty = '';
|
14397 |
-
|
14398 |
-
var _stateDefault = _empty + 'ui-state-default';
|
14399 |
-
var _sortIcon = _empty + 'css_right ui-icon ui-icon-';
|
14400 |
-
var _headerFooter = _empty + 'fg-toolbar ui-toolbar ui-widget-header ui-helper-clearfix';
|
14401 |
-
|
14402 |
-
$.extend( DataTable.ext.oJUIClasses, DataTable.ext.classes, {
|
14403 |
-
/* Full numbers paging buttons */
|
14404 |
-
"sPageButton": "fg-button ui-button "+_stateDefault,
|
14405 |
-
"sPageButtonActive": "ui-state-disabled",
|
14406 |
-
"sPageButtonDisabled": "ui-state-disabled",
|
14407 |
-
|
14408 |
-
/* Features */
|
14409 |
-
"sPaging": "dataTables_paginate fg-buttonset ui-buttonset fg-buttonset-multi "+
|
14410 |
-
"ui-buttonset-multi paging_", /* Note that the type is postfixed */
|
14411 |
-
|
14412 |
-
/* Sorting */
|
14413 |
-
"sSortAsc": _stateDefault+" sorting_asc",
|
14414 |
-
"sSortDesc": _stateDefault+" sorting_desc",
|
14415 |
-
"sSortable": _stateDefault+" sorting",
|
14416 |
-
"sSortableAsc": _stateDefault+" sorting_asc_disabled",
|
14417 |
-
"sSortableDesc": _stateDefault+" sorting_desc_disabled",
|
14418 |
-
"sSortableNone": _stateDefault+" sorting_disabled",
|
14419 |
-
"sSortJUIAsc": _sortIcon+"triangle-1-n",
|
14420 |
-
"sSortJUIDesc": _sortIcon+"triangle-1-s",
|
14421 |
-
"sSortJUI": _sortIcon+"carat-2-n-s",
|
14422 |
-
"sSortJUIAscAllowed": _sortIcon+"carat-1-n",
|
14423 |
-
"sSortJUIDescAllowed": _sortIcon+"carat-1-s",
|
14424 |
-
"sSortJUIWrapper": "DataTables_sort_wrapper",
|
14425 |
-
"sSortIcon": "DataTables_sort_icon",
|
14426 |
-
|
14427 |
-
/* Scrolling */
|
14428 |
-
"sScrollHead": "dataTables_scrollHead "+_stateDefault,
|
14429 |
-
"sScrollFoot": "dataTables_scrollFoot "+_stateDefault,
|
14430 |
-
|
14431 |
-
/* Misc */
|
14432 |
-
"sHeaderTH": _stateDefault,
|
14433 |
-
"sFooterTH": _stateDefault,
|
14434 |
-
"sJUIHeader": _headerFooter+" ui-corner-tl ui-corner-tr",
|
14435 |
-
"sJUIFooter": _headerFooter+" ui-corner-bl ui-corner-br"
|
14436 |
-
} );
|
14437 |
-
|
14438 |
-
}());
|
14439 |
-
|
14440 |
-
|
14441 |
-
|
14442 |
var extPagination = DataTable.ext.pager;
|
14443 |
|
14444 |
function _numbers ( page, pages ) {
|
@@ -14494,6 +14466,10 @@
|
|
14494 |
full_numbers: function ( page, pages ) {
|
14495 |
return [ 'first', 'previous', _numbers(page, pages), 'next', 'last' ];
|
14496 |
},
|
|
|
|
|
|
|
|
|
14497 |
|
14498 |
// For testing and plug-ins to use
|
14499 |
_numbers: _numbers,
|
@@ -14605,7 +14581,7 @@
|
|
14605 |
|
14606 |
attach( $(host).empty(), buttons );
|
14607 |
|
14608 |
-
if ( activeEl ) {
|
14609 |
$(host).find( '[data-dt-idx='+activeEl+']' ).focus();
|
14610 |
}
|
14611 |
}
|
@@ -14628,10 +14604,10 @@
|
|
14628 |
// Dates (only those recognised by the browser's Date.parse)
|
14629 |
function ( d, settings )
|
14630 |
{
|
14631 |
-
// V8
|
14632 |
-
//
|
14633 |
-
//
|
14634 |
-
if ( d && !(d instanceof Date) &&
|
14635 |
return null;
|
14636 |
}
|
14637 |
var parsed = Date.parse(d);
|
@@ -14768,7 +14744,7 @@
|
|
14768 |
$.extend( _ext.type.order, {
|
14769 |
// Dates
|
14770 |
"date-pre": function ( d ) {
|
14771 |
-
return Date.parse( d ) ||
|
14772 |
},
|
14773 |
|
14774 |
// html
|
@@ -14939,6 +14915,7 @@
|
|
14939 |
return __htmlEscapeEntities( d );
|
14940 |
}
|
14941 |
|
|
|
14942 |
d = Math.abs( flo );
|
14943 |
|
14944 |
var intPart = parseInt( d, 10 );
|
@@ -15276,3 +15253,12536 @@
|
|
15276 |
|
15277 |
return $.fn.dataTable;
|
15278 |
}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* This combined file was created by the DataTables downloader builder:
|
3 |
+
* https://datatables.net/download
|
4 |
+
*
|
5 |
+
* To rebuild or modify this file with the latest versions of the included
|
6 |
+
* software please visit:
|
7 |
+
* https://datatables.net/download/#dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5
|
8 |
+
*
|
9 |
+
* Included libraries:
|
10 |
+
* DataTables 1.10.16, AutoFill 2.2.2, Buttons 1.5.1, ColReorder 1.4.1, FixedColumns 3.2.4, FixedHeader 3.1.3, KeyTable 2.3.2, Responsive 2.2.1, RowReorder 1.2.3, Scroller 1.4.4, Select 1.2.5
|
11 |
+
*/
|
12 |
+
|
13 |
+
/*! DataTables 1.10.16
|
14 |
+
* ©2008-2017 SpryMedia Ltd - datatables.net/license
|
15 |
*/
|
16 |
|
17 |
/**
|
18 |
* @summary DataTables
|
19 |
* @description Paginate, search and order HTML tables
|
20 |
+
* @version 1.10.16
|
21 |
* @file jquery.dataTables.js
|
22 |
+
* @author SpryMedia Ltd
|
23 |
+
* @contact www.datatables.net
|
24 |
+
* @copyright Copyright 2008-2017 SpryMedia Ltd.
|
25 |
*
|
26 |
* This source file is free software, available under the following license:
|
27 |
* MIT license - http://datatables.net/license
|
291 |
* "bPaginate": false
|
292 |
* } );
|
293 |
*
|
294 |
+
* $(window).on('resize', function () {
|
295 |
* oTable.fnAdjustColumnSizing();
|
296 |
* } );
|
297 |
* } );
|
1035 |
[ "iCookieDuration", "iStateDuration" ], // backwards compat
|
1036 |
[ "oSearch", "oPreviousSearch" ],
|
1037 |
[ "aoSearchCols", "aoPreSearchCols" ],
|
1038 |
+
[ "iDisplayLength", "_iDisplayLength" ]
|
|
|
1039 |
] );
|
1040 |
_fnMap( oSettings.oScroll, oInit, [
|
1041 |
[ "sScrollX", "sX" ],
|
1065 |
|
1066 |
var oClasses = oSettings.oClasses;
|
1067 |
|
1068 |
+
$.extend( oClasses, DataTable.ext.classes, oInit.oClasses );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1069 |
$this.addClass( oClasses.sTable );
|
1070 |
|
1071 |
|
1088 |
var oLanguage = oSettings.oLanguage;
|
1089 |
$.extend( true, oLanguage, oInit.oLanguage );
|
1090 |
|
1091 |
+
if ( oLanguage.sUrl )
|
1092 |
{
|
1093 |
/* Get the language definitions from a file - because this Ajax call makes the language
|
1094 |
* get async to the remainder of this function we use bInitHandedOff to indicate that
|
1200 |
}
|
1201 |
|
1202 |
var features = oSettings.oFeatures;
|
1203 |
+
var loadedInit = function () {
|
1204 |
+
/*
|
1205 |
+
* Sorting
|
1206 |
+
* @todo For modularisation (1.11) this needs to do into a sort start up handler
|
1207 |
+
*/
|
1208 |
|
1209 |
+
// If aaSorting is not defined, then we use the first indicator in asSorting
|
1210 |
+
// in case that has been altered, so the default sort reflects that option
|
1211 |
+
if ( oInit.aaSorting === undefined ) {
|
1212 |
+
var sorting = oSettings.aaSorting;
|
1213 |
+
for ( i=0, iLen=sorting.length ; i<iLen ; i++ ) {
|
1214 |
+
sorting[i][1] = oSettings.aoColumns[ i ].asSorting[0];
|
1215 |
+
}
|
1216 |
+
}
|
1217 |
|
1218 |
+
/* Do a first pass on the sorting classes (allows any size changes to be taken into
|
1219 |
+
* account, and also will apply sorting disabled classes if disabled
|
1220 |
+
*/
|
1221 |
+
_fnSortingClasses( oSettings );
|
1222 |
|
1223 |
+
if ( features.bSort ) {
|
1224 |
+
_fnCallbackReg( oSettings, 'aoDrawCallback', function () {
|
1225 |
+
if ( oSettings.bSorted ) {
|
1226 |
+
var aSort = _fnSortFlatten( oSettings );
|
1227 |
+
var sortedColumns = {};
|
1228 |
|
1229 |
+
$.each( aSort, function (i, val) {
|
1230 |
+
sortedColumns[ val.src ] = val.dir;
|
1231 |
+
} );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1232 |
|
1233 |
+
_fnCallbackFire( oSettings, null, 'order', [oSettings, aSort, sortedColumns] );
|
1234 |
+
_fnSortAria( oSettings );
|
1235 |
+
}
|
1236 |
+
} );
|
1237 |
+
}
|
1238 |
|
|
|
|
|
1239 |
_fnCallbackReg( oSettings, 'aoDrawCallback', function () {
|
1240 |
+
if ( oSettings.bSorted || _fnDataSource( oSettings ) === 'ssp' || features.bDeferRender ) {
|
1241 |
+
_fnSortingClasses( oSettings );
|
1242 |
+
}
|
1243 |
+
}, 'sc' );
|
1244 |
|
|
|
|
|
|
|
1245 |
|
1246 |
+
/*
|
1247 |
+
* Final init
|
1248 |
+
* Cache the header, body and footer as required, creating them if needed
|
1249 |
+
*/
|
1250 |
+
|
1251 |
+
// Work around for Webkit bug 83867 - store the caption-side before removing from doc
|
1252 |
+
var captions = $this.children('caption').each( function () {
|
1253 |
+
this._captionSide = $(this).css('caption-side');
|
1254 |
} );
|
|
|
1255 |
|
1256 |
+
var thead = $this.children('thead');
|
1257 |
+
if ( thead.length === 0 ) {
|
1258 |
+
thead = $('<thead/>').appendTo($this);
|
1259 |
}
|
1260 |
+
oSettings.nTHead = thead[0];
|
1261 |
|
1262 |
+
var tbody = $this.children('tbody');
|
1263 |
+
if ( tbody.length === 0 ) {
|
1264 |
+
tbody = $('<tbody/>').appendTo($this);
|
1265 |
+
}
|
1266 |
+
oSettings.nTBody = tbody[0];
|
1267 |
|
1268 |
+
var tfoot = $this.children('tfoot');
|
1269 |
+
if ( tfoot.length === 0 && captions.length > 0 && (oSettings.oScroll.sX !== "" || oSettings.oScroll.sY !== "") ) {
|
1270 |
+
// If we are a scrolling table, and no footer has been given, then we need to create
|
1271 |
+
// a tfoot element for the caption element to be appended to
|
1272 |
+
tfoot = $('<tfoot/>').appendTo($this);
|
1273 |
+
}
|
1274 |
|
1275 |
+
if ( tfoot.length === 0 || tfoot.children().length === 0 ) {
|
1276 |
+
$this.addClass( oClasses.sNoFooter );
|
1277 |
+
}
|
1278 |
+
else if ( tfoot.length > 0 ) {
|
1279 |
+
oSettings.nTFoot = tfoot[0];
|
1280 |
+
_fnDetectHeader( oSettings.aoFooter, oSettings.nTFoot );
|
1281 |
+
}
|
1282 |
|
1283 |
+
/* Check if there is data passing into the constructor */
|
1284 |
+
if ( oInit.aaData ) {
|
1285 |
+
for ( i=0 ; i<oInit.aaData.length ; i++ ) {
|
1286 |
+
_fnAddData( oSettings, oInit.aaData[ i ] );
|
1287 |
+
}
|
1288 |
+
}
|
1289 |
+
else if ( oSettings.bDeferLoading || _fnDataSource( oSettings ) == 'dom' ) {
|
1290 |
+
/* Grab the data from the page - only do this when deferred loading or no Ajax
|
1291 |
+
* source since there is no point in reading the DOM data if we are then going
|
1292 |
+
* to replace it with Ajax data
|
1293 |
+
*/
|
1294 |
+
_fnAddTr( oSettings, $(oSettings.nTBody).children('tr') );
|
1295 |
+
}
|
1296 |
|
1297 |
+
/* Copy the data index array */
|
1298 |
+
oSettings.aiDisplay = oSettings.aiDisplayMaster.slice();
|
|
|
|
|
|
|
|
|
1299 |
|
1300 |
+
/* Initialisation complete - table can be drawn */
|
1301 |
+
oSettings.bInitialised = true;
|
|
|
|
|
|
|
|
|
|
|
1302 |
|
1303 |
+
/* Check if we need to initialise the table (it might not have been handed off to the
|
1304 |
+
* language processor)
|
1305 |
+
*/
|
1306 |
+
if ( bInitHandedOff === false ) {
|
1307 |
+
_fnInitialise( oSettings );
|
1308 |
+
}
|
1309 |
+
};
|
1310 |
|
1311 |
+
/* Must be done after everything which can be overridden by the state saving! */
|
1312 |
+
if ( oInit.bStateSave )
|
1313 |
{
|
1314 |
+
features.bStateSave = true;
|
1315 |
+
_fnCallbackReg( oSettings, 'aoDrawCallback', _fnSaveState, 'state_save' );
|
1316 |
+
_fnLoadState( oSettings, oInit, loadedInit );
|
|
|
1317 |
}
|
1318 |
+
else {
|
1319 |
+
loadedInit();
|
|
|
|
|
|
|
|
|
|
|
1320 |
}
|
1321 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1322 |
} );
|
1323 |
_that = null;
|
1324 |
return this;
|
1349 |
var _re_dic = {};
|
1350 |
var _re_new_lines = /[\r\n]/g;
|
1351 |
var _re_html = /<.*?>/g;
|
1352 |
+
|
1353 |
+
// This is not strict ISO8601 - Date.parse() is quite lax, although
|
1354 |
+
// implementations differ between browsers.
|
1355 |
+
var _re_date = /^\d{2,4}[\.\/\-]\d{1,2}[\.\/\-]\d{1,2}([T ]{1}\d{1,2}[:\.]\d{2}([\.:]\d{2})?)?$/;
|
1356 |
|
1357 |
// Escape regular expression special characters
|
1358 |
var _re_escape_regex = new RegExp( '(\\' + [ '/', '.', '*', '+', '?', '|', '(', ')', '[', ']', '{', '}', '\\', '$', '^', '-' ].join('|\\') + ')', 'g' );
|
1527 |
};
|
1528 |
|
1529 |
|
1530 |
+
/**
|
1531 |
+
* Determine if all values in the array are unique. This means we can short
|
1532 |
+
* cut the _unique method at the cost of a single loop. A sorted array is used
|
1533 |
+
* to easily check the values.
|
1534 |
+
*
|
1535 |
+
* @param {array} src Source array
|
1536 |
+
* @return {boolean} true if all unique, false otherwise
|
1537 |
+
* @ignore
|
1538 |
+
*/
|
1539 |
+
var _areAllUnique = function ( src ) {
|
1540 |
+
if ( src.length < 2 ) {
|
1541 |
+
return true;
|
1542 |
+
}
|
1543 |
+
|
1544 |
+
var sorted = src.slice().sort();
|
1545 |
+
var last = sorted[0];
|
1546 |
+
|
1547 |
+
for ( var i=1, ien=sorted.length ; i<ien ; i++ ) {
|
1548 |
+
if ( sorted[i] === last ) {
|
1549 |
+
return false;
|
1550 |
+
}
|
1551 |
+
|
1552 |
+
last = sorted[i];
|
1553 |
+
}
|
1554 |
+
|
1555 |
+
return true;
|
1556 |
+
};
|
1557 |
+
|
1558 |
+
|
1559 |
/**
|
1560 |
* Find the unique elements in a source array.
|
1561 |
*
|
1565 |
*/
|
1566 |
var _unique = function ( src )
|
1567 |
{
|
1568 |
+
if ( _areAllUnique( src ) ) {
|
1569 |
+
return src.slice();
|
1570 |
+
}
|
1571 |
+
|
1572 |
// A faster unique method is to use object keys to identify used values,
|
1573 |
// but this doesn't work with arrays or objects, which we must also
|
1574 |
// consider. See jsperf.com/compare-array-unique-versions/4 for more
|
1842 |
|
1843 |
// orderData can be given as an integer
|
1844 |
var dataSort = init.aDataSort;
|
1845 |
+
if ( typeof dataSort === 'number' && ! $.isArray( dataSort ) ) {
|
1846 |
init.aDataSort = [ dataSort ];
|
1847 |
}
|
1848 |
}
|
1867 |
.css( {
|
1868 |
position: 'fixed',
|
1869 |
top: 0,
|
1870 |
+
left: $(window).scrollLeft()*-1, // allow for scrolling
|
1871 |
height: 1,
|
1872 |
width: 1,
|
1873 |
overflow: 'hidden'
|
2044 |
{
|
2045 |
oOptions.sClass = oOptions.className;
|
2046 |
}
|
2047 |
+
if ( oOptions.sClass ) {
|
2048 |
+
th.addClass( oOptions.sClass );
|
2049 |
+
}
|
2050 |
|
2051 |
$.extend( oCol, oOptions );
|
2052 |
_fnMap( oCol, oOptions, "sWidth", "sWidthOrig" );
|
2563 |
function _fnSplitObjNotation( str )
|
2564 |
{
|
2565 |
return $.map( str.match(/(\\.|[^\.])+/g) || [''], function ( s ) {
|
2566 |
+
return s.replace(/\\\./g, '.');
|
2567 |
} );
|
2568 |
}
|
2569 |
|
4221 |
var jqFilter = $('input', filter)
|
4222 |
.val( previousSearch.sSearch )
|
4223 |
.attr( 'placeholder', language.sSearchPlaceholder )
|
4224 |
+
.on(
|
4225 |
'keyup.DT search.DT input.DT paste.DT cut.DT',
|
4226 |
searchDelay ?
|
4227 |
_fnThrottle( searchFn, searchDelay ) :
|
4228 |
searchFn
|
4229 |
)
|
4230 |
+
.on( 'keypress.DT', function(e) {
|
4231 |
/* Prevent form submission */
|
4232 |
if ( e.keyCode == 13 ) {
|
4233 |
return false;
|
4357 |
}
|
4358 |
|
4359 |
var data;
|
4360 |
+
var out = [];
|
4361 |
var display = settings.aiDisplay;
|
4362 |
var rpSearch = _fnFilterCreateSearch( searchStr, regex, smart, caseInsensitive );
|
4363 |
|
4364 |
+
for ( var i=0 ; i<display.length ; i++ ) {
|
4365 |
data = settings.aoData[ display[i] ]._aFilterData[ colIdx ];
|
4366 |
|
4367 |
+
if ( rpSearch.test( data ) ) {
|
4368 |
+
out.push( display[i] );
|
4369 |
}
|
4370 |
}
|
4371 |
+
|
4372 |
+
settings.aiDisplay = out;
|
4373 |
}
|
4374 |
|
4375 |
|
4389 |
var prevSearch = settings.oPreviousSearch.sSearch;
|
4390 |
var displayMaster = settings.aiDisplayMaster;
|
4391 |
var display, invalidated, i;
|
4392 |
+
var filtered = [];
|
4393 |
|
4394 |
// Need to take account of custom filtering functions - always filter
|
4395 |
if ( DataTable.ext.search.length !== 0 ) {
|
4418 |
// Search the display array
|
4419 |
display = settings.aiDisplay;
|
4420 |
|
4421 |
+
for ( i=0 ; i<display.length ; i++ ) {
|
4422 |
+
if ( rpSearch.test( settings.aoData[ display[i] ]._sFilterRow ) ) {
|
4423 |
+
filtered.push( display[i] );
|
4424 |
}
|
4425 |
}
|
4426 |
+
|
4427 |
+
settings.aiDisplay = filtered;
|
4428 |
}
|
4429 |
}
|
4430 |
|
4821 |
} );
|
4822 |
|
4823 |
for ( var i=0, ien=lengths.length ; i<ien ; i++ ) {
|
4824 |
+
select[0][ i ] = new Option(
|
4825 |
+
typeof language[i] === 'number' ?
|
4826 |
+
settings.fnFormatNumber( language[i] ) :
|
4827 |
+
language[i],
|
4828 |
+
lengths[i]
|
4829 |
+
);
|
4830 |
}
|
4831 |
|
4832 |
var div = $('<div><label/></div>').addClass( classes.sLength );
|
4842 |
// reference is broken by the use of outerHTML
|
4843 |
$('select', div)
|
4844 |
.val( settings._iDisplayLength )
|
4845 |
+
.on( 'change.DT', function(e) {
|
4846 |
_fnLengthChange( settings, $(this).val() );
|
4847 |
_fnDraw( settings );
|
4848 |
} );
|
4849 |
|
4850 |
// Update node value whenever anything changes the table's length
|
4851 |
+
$(settings.nTable).on( 'length.dt.DT', function (e, s, len) {
|
4852 |
if ( settings === s ) {
|
4853 |
$('select', div).val( len );
|
4854 |
}
|
5713 |
|
5714 |
if ( (tableWidthAttr || scrollX) && ! oSettings._reszEvt ) {
|
5715 |
var bindResize = function () {
|
5716 |
+
$(window).on('resize.DT-'+oSettings.sInstance, _fnThrottle( function () {
|
5717 |
_fnAdjustColumnSizing( oSettings );
|
5718 |
} ) );
|
5719 |
};
|
6324 |
* Attempt to load a saved table state
|
6325 |
* @param {object} oSettings dataTables settings object
|
6326 |
* @param {object} oInit DataTables init object so we can override settings
|
6327 |
+
* @param {function} callback Callback to execute when the state has been loaded
|
6328 |
* @memberof DataTable#oApi
|
6329 |
*/
|
6330 |
+
function _fnLoadState ( settings, oInit, callback )
|
6331 |
{
|
6332 |
var i, ien;
|
6333 |
var columns = settings.aoColumns;
|
6334 |
+
var loaded = function ( s ) {
|
6335 |
+
if ( ! s || ! s.time ) {
|
6336 |
+
callback();
|
6337 |
+
return;
|
6338 |
+
}
|
6339 |
|
6340 |
+
// Allow custom and plug-in manipulation functions to alter the saved data set and
|
6341 |
+
// cancelling of loading by returning false
|
6342 |
+
var abStateLoad = _fnCallbackFire( settings, 'aoStateLoadParams', 'stateLoadParams', [settings, s] );
|
6343 |
+
if ( $.inArray( false, abStateLoad ) !== -1 ) {
|
6344 |
+
callback();
|
6345 |
+
return;
|
6346 |
+
}
|
|
|
6347 |
|
6348 |
+
// Reject old data
|
6349 |
+
var duration = settings.iStateDuration;
|
6350 |
+
if ( duration > 0 && s.time < +new Date() - (duration*1000) ) {
|
6351 |
+
callback();
|
6352 |
+
return;
|
6353 |
+
}
|
|
|
6354 |
|
6355 |
+
// Number of columns have changed - all bets are off, no restore of settings
|
6356 |
+
if ( s.columns && columns.length !== s.columns.length ) {
|
6357 |
+
callback();
|
6358 |
+
return;
|
6359 |
+
}
|
6360 |
|
6361 |
+
// Store the saved state so it might be accessed at any time
|
6362 |
+
settings.oLoadedState = $.extend( true, {}, s );
|
|
|
|
|
6363 |
|
6364 |
+
// Restore key features - todo - for 1.11 this needs to be done by
|
6365 |
+
// subscribed events
|
6366 |
+
if ( s.start !== undefined ) {
|
6367 |
+
settings._iDisplayStart = s.start;
|
6368 |
+
settings.iInitDisplayStart = s.start;
|
6369 |
+
}
|
6370 |
+
if ( s.length !== undefined ) {
|
6371 |
+
settings._iDisplayLength = s.length;
|
6372 |
+
}
|
6373 |
|
6374 |
+
// Order
|
6375 |
+
if ( s.order !== undefined ) {
|
6376 |
+
settings.aaSorting = [];
|
6377 |
+
$.each( s.order, function ( i, col ) {
|
6378 |
+
settings.aaSorting.push( col[0] >= columns.length ?
|
6379 |
+
[ 0, col[1] ] :
|
6380 |
+
col
|
6381 |
+
);
|
6382 |
+
} );
|
6383 |
+
}
|
6384 |
|
6385 |
+
// Search
|
6386 |
+
if ( s.search !== undefined ) {
|
6387 |
+
$.extend( settings.oPreviousSearch, _fnSearchToHung( s.search ) );
|
6388 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
6389 |
|
6390 |
+
// Columns
|
6391 |
+
//
|
6392 |
+
if ( s.columns ) {
|
6393 |
+
for ( i=0, ien=s.columns.length ; i<ien ; i++ ) {
|
6394 |
+
var col = s.columns[i];
|
6395 |
|
6396 |
+
// Visibility
|
6397 |
+
if ( col.visible !== undefined ) {
|
6398 |
+
columns[i].bVisible = col.visible;
|
6399 |
+
}
|
6400 |
|
6401 |
+
// Search
|
6402 |
+
if ( col.search !== undefined ) {
|
6403 |
+
$.extend( settings.aoPreSearchCols[i], _fnSearchToHung( col.search ) );
|
6404 |
+
}
|
6405 |
+
}
|
6406 |
}
|
6407 |
|
6408 |
+
_fnCallbackFire( settings, 'aoStateLoaded', 'stateLoaded', [settings, s] );
|
6409 |
+
callback();
|
6410 |
+
}
|
6411 |
+
|
6412 |
+
if ( ! settings.oFeatures.bStateSave ) {
|
6413 |
+
callback();
|
6414 |
+
return;
|
6415 |
}
|
6416 |
|
6417 |
+
var state = settings.fnStateLoadCallback.call( settings.oInstance, settings, loaded );
|
6418 |
+
|
6419 |
+
if ( state !== undefined ) {
|
6420 |
+
loaded( state );
|
6421 |
+
}
|
6422 |
+
// otherwise, wait for the loaded callback to be executed
|
6423 |
}
|
6424 |
|
6425 |
|
6572 |
function _fnBindAction( n, oData, fn )
|
6573 |
{
|
6574 |
$(n)
|
6575 |
+
.on( 'click.DT', oData, function (e) {
|
6576 |
n.blur(); // Remove focus outline for mouse users
|
6577 |
fn(e);
|
6578 |
} )
|
6579 |
+
.on( 'keypress.DT', oData, function (e){
|
6580 |
if ( e.which === 13 ) {
|
6581 |
e.preventDefault();
|
6582 |
fn(e);
|
6583 |
}
|
6584 |
} )
|
6585 |
+
.on( 'selectstart.DT', function () {
|
6586 |
/* Take the brutal approach to cancelling text selection */
|
6587 |
return false;
|
6588 |
} );
|
7137 |
shift: __arrayProto.shift,
|
7138 |
|
7139 |
|
7140 |
+
slice: function () {
|
7141 |
+
return new _Api( this.context, this );
|
7142 |
+
},
|
7143 |
+
|
7144 |
+
|
7145 |
sort: __arrayProto.sort, // ? name - order?
|
7146 |
|
7147 |
|
7715 |
}
|
7716 |
|
7717 |
for ( i=0, ien=selector.length ; i<ien ; i++ ) {
|
7718 |
+
// Only split on simple strings - complex expressions will be jQuery selectors
|
7719 |
+
a = selector[i] && selector[i].split && ! selector[i].match(/[\[\(:]/) ?
|
7720 |
selector[i].split(',') :
|
7721 |
[ selector[i] ];
|
7722 |
|
7856 |
|
7857 |
var __row_selector = function ( settings, selector, opts )
|
7858 |
{
|
7859 |
+
var rows;
|
7860 |
var run = function ( sel ) {
|
7861 |
var selInt = _intVal( sel );
|
7862 |
var i, ien;
|
7868 |
return [ selInt ];
|
7869 |
}
|
7870 |
|
7871 |
+
if ( ! rows ) {
|
7872 |
+
rows = _selector_row_indexes( settings, opts );
|
7873 |
+
}
|
7874 |
|
7875 |
if ( selInt !== null && $.inArray( selInt, rows ) !== -1 ) {
|
7876 |
// Selector - integer
|
7877 |
return [ selInt ];
|
7878 |
}
|
7879 |
+
else if ( sel === null || sel === undefined || sel === '' ) {
|
7880 |
// Selector - none
|
7881 |
return rows;
|
7882 |
}
|
8048 |
_fnDeleteIndex( settings.aiDisplay, row );
|
8049 |
_fnDeleteIndex( that[ thatIdx ], row, false ); // maintain local indexes
|
8050 |
|
8051 |
+
// For server-side processing tables - subtract the deleted row from the count
|
8052 |
+
if ( settings._iRecordsDisplay > 0 ) {
|
8053 |
+
settings._iRecordsDisplay--;
|
8054 |
+
}
|
8055 |
+
|
8056 |
// Check for an 'overflow' they case for displaying the table
|
8057 |
_fnLengthOverflow( settings );
|
8058 |
|
8194 |
addRow( data, klass );
|
8195 |
|
8196 |
if ( row._details ) {
|
8197 |
+
row._details.detach();
|
8198 |
}
|
8199 |
|
8200 |
row._details = $(rows);
|
8395 |
// can be an array of these items, comma separated list, or an array of comma
|
8396 |
// separated lists
|
8397 |
|
8398 |
+
var __re_column_selector = /^([^:]+):(name|visIdx|visible)$/;
|
8399 |
|
8400 |
|
8401 |
// r1 and r2 are redundant - but it means that the parameters match for the
|
9142 |
var t = $(table).get(0);
|
9143 |
var is = false;
|
9144 |
|
9145 |
+
if ( table instanceof DataTable.Api ) {
|
9146 |
+
return true;
|
9147 |
+
}
|
9148 |
+
|
9149 |
$.each( DataTable.settings, function (i, o) {
|
9150 |
var head = o.nScrollHead ? $('table', o.nScrollHead)[0] : null;
|
9151 |
var foot = o.nScrollFoot ? $('table', o.nScrollFoot)[0] : null;
|
9234 |
var args = Array.prototype.slice.call(arguments);
|
9235 |
|
9236 |
// Add the `dt` namespace automatically if it isn't already present
|
9237 |
+
args[0] = $.map( args[0].split( /\s/ ), function ( e ) {
|
9238 |
+
return ! e.match(/\.dt\b/) ?
|
9239 |
+
e+'.dt' :
|
9240 |
+
e;
|
9241 |
+
} ).join( ' ' );
|
9242 |
|
9243 |
var inst = $( this.tables().nodes() );
|
9244 |
inst[key].apply( inst, args );
|
9303 |
// Blitz all `DT` namespaced events (these are internal events, the
|
9304 |
// lowercase, `dt` events are user subscribed and they are responsible
|
9305 |
// for removing them
|
9306 |
+
jqWrapper.off('.DT').find(':not(tbody *)').off('.DT');
|
9307 |
+
$(window).off('.DT-'+settings.sInstance);
|
9308 |
|
9309 |
// When scrolling we had to break the table up - restore it
|
9310 |
if ( table != thead.parentNode ) {
|
9327 |
classes.sSortableAsc+' '+classes.sSortableDesc+' '+classes.sSortableNone
|
9328 |
);
|
9329 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9330 |
// Add the TR elements back into the table in their original order
|
9331 |
jqTbody.children().detach();
|
9332 |
jqTbody.append( rows );
|
9425 |
* @type string
|
9426 |
* @default Version number
|
9427 |
*/
|
9428 |
+
DataTable.version = "1.10.16";
|
9429 |
|
9430 |
/**
|
9431 |
* Private data store, containing all of the settings objects that are
|
10354 |
"bInfo": true,
|
10355 |
|
10356 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10357 |
/**
|
10358 |
* Allows the end user to select the size of a formatted page from a select
|
10359 |
* menu (sizes are 10, 25, 50 and 100). Requires pagination (`paginate`).
|
10913 |
* @type function
|
10914 |
* @member
|
10915 |
* @param {object} settings DataTables settings object
|
10916 |
+
* @param {object} callback Callback that can be executed when done. It
|
10917 |
+
* should be passed the loaded state object.
|
10918 |
* @return {object} The DataTables state object to be loaded
|
10919 |
*
|
10920 |
* @dtopt Callbacks
|
10924 |
* $(document).ready( function() {
|
10925 |
* $('#example').dataTable( {
|
10926 |
* "stateSave": true,
|
10927 |
+
* "stateLoadCallback": function (settings, callback) {
|
|
|
|
|
|
|
|
|
10928 |
* $.ajax( {
|
10929 |
* "url": "/state_load",
|
|
|
10930 |
* "dataType": "json",
|
10931 |
* "success": function (json) {
|
10932 |
+
* callback( json );
|
10933 |
* }
|
10934 |
* } );
|
|
|
|
|
10935 |
* }
|
10936 |
* } );
|
10937 |
* } );
|
11870 |
|
11871 |
|
11872 |
/**
|
11873 |
+
* DataTables features six different built-in options for the buttons to
|
11874 |
* display for pagination control:
|
11875 |
*
|
11876 |
+
* * `numbers` - Page number buttons only
|
11877 |
* * `simple` - 'Previous' and 'Next' buttons only
|
11878 |
* * 'simple_numbers` - 'Previous' and 'Next' buttons, plus page numbers
|
11879 |
* * `full` - 'First', 'Previous', 'Next' and 'Last' buttons
|
11880 |
+
* * `full_numbers` - 'First', 'Previous', 'Next' and 'Last' buttons, plus page numbers
|
11881 |
+
* * `first_last_numbers` - 'First' and 'Last' buttons, plus page numbers
|
11882 |
*
|
11883 |
* Further methods can be added using {@link DataTable.ext.oPagination}.
|
11884 |
* @type string
|
13634 |
*/
|
13635 |
"_iRecordsDisplay": 0,
|
13636 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13637 |
/**
|
13638 |
* The classes to use for the table
|
13639 |
* @type object
|
13847 |
*
|
13848 |
* @type string
|
13849 |
*/
|
13850 |
+
build:"dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5",
|
13851 |
|
13852 |
|
13853 |
/**
|
14411 |
} );
|
14412 |
|
14413 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14414 |
var extPagination = DataTable.ext.pager;
|
14415 |
|
14416 |
function _numbers ( page, pages ) {
|
14466 |
full_numbers: function ( page, pages ) {
|
14467 |
return [ 'first', 'previous', _numbers(page, pages), 'next', 'last' ];
|
14468 |
},
|
14469 |
+
|
14470 |
+
first_last_numbers: function (page, pages) {
|
14471 |
+
return ['first', _numbers(page, pages), 'last'];
|
14472 |
+
},
|
14473 |
|
14474 |
// For testing and plug-ins to use
|
14475 |
_numbers: _numbers,
|
14581 |
|
14582 |
attach( $(host).empty(), buttons );
|
14583 |
|
14584 |
+
if ( activeEl !== undefined ) {
|
14585 |
$(host).find( '[data-dt-idx='+activeEl+']' ).focus();
|
14586 |
}
|
14587 |
}
|
14604 |
// Dates (only those recognised by the browser's Date.parse)
|
14605 |
function ( d, settings )
|
14606 |
{
|
14607 |
+
// V8 tries _very_ hard to make a string passed into `Date.parse()`
|
14608 |
+
// valid, so we need to use a regex to restrict date formats. Use a
|
14609 |
+
// plug-in for anything other than ISO8601 style strings
|
14610 |
+
if ( d && !(d instanceof Date) && ! _re_date.test(d) ) {
|
14611 |
return null;
|
14612 |
}
|
14613 |
var parsed = Date.parse(d);
|
14744 |
$.extend( _ext.type.order, {
|
14745 |
// Dates
|
14746 |
"date-pre": function ( d ) {
|
14747 |
+
return Date.parse( d ) || -Infinity;
|
14748 |
},
|
14749 |
|
14750 |
// html
|
14915 |
return __htmlEscapeEntities( d );
|
14916 |
}
|
14917 |
|
14918 |
+
flo = flo.toFixed( precision );
|
14919 |
d = Math.abs( flo );
|
14920 |
|
14921 |
var intPart = parseInt( d, 10 );
|
15253 |
|
15254 |
return $.fn.dataTable;
|
15255 |
}));
|
15256 |
+
|
15257 |
+
|
15258 |
+
/*! AutoFill 2.2.2
|
15259 |
+
* ©2008-2017 SpryMedia Ltd - datatables.net/license
|
15260 |
+
*/
|
15261 |
+
|
15262 |
+
/**
|
15263 |
+
* @summary AutoFill
|
15264 |
+
* @description Add Excel like click and drag auto-fill options to DataTables
|
15265 |
+
* @version 2.2.2
|
15266 |
+
* @file dataTables.autoFill.js
|
15267 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
15268 |
+
* @contact www.sprymedia.co.uk/contact
|
15269 |
+
* @copyright Copyright 2010-2017 SpryMedia Ltd.
|
15270 |
+
*
|
15271 |
+
* This source file is free software, available under the following license:
|
15272 |
+
* MIT license - http://datatables.net/license/mit
|
15273 |
+
*
|
15274 |
+
* This source file is distributed in the hope that it will be useful, but
|
15275 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
15276 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
15277 |
+
*
|
15278 |
+
* For details please refer to: http://www.datatables.net
|
15279 |
+
*/
|
15280 |
+
(function( factory ){
|
15281 |
+
if ( typeof define === 'function' && define.amd ) {
|
15282 |
+
// AMD
|
15283 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
15284 |
+
return factory( $, window, document );
|
15285 |
+
} );
|
15286 |
+
}
|
15287 |
+
else if ( typeof exports === 'object' ) {
|
15288 |
+
// CommonJS
|
15289 |
+
module.exports = function (root, $) {
|
15290 |
+
if ( ! root ) {
|
15291 |
+
root = window;
|
15292 |
+
}
|
15293 |
+
|
15294 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
15295 |
+
$ = require('datatables.net')(root, $).$;
|
15296 |
+
}
|
15297 |
+
|
15298 |
+
return factory( $, root, root.document );
|
15299 |
+
};
|
15300 |
+
}
|
15301 |
+
else {
|
15302 |
+
// Browser
|
15303 |
+
factory( jQuery, window, document );
|
15304 |
+
}
|
15305 |
+
}(function( $, window, document, undefined ) {
|
15306 |
+
'use strict';
|
15307 |
+
var DataTable = $.fn.dataTable;
|
15308 |
+
|
15309 |
+
|
15310 |
+
var _instance = 0;
|
15311 |
+
|
15312 |
+
/**
|
15313 |
+
* AutoFill provides Excel like auto-fill features for a DataTable
|
15314 |
+
*
|
15315 |
+
* @class AutoFill
|
15316 |
+
* @constructor
|
15317 |
+
* @param {object} oTD DataTables settings object
|
15318 |
+
* @param {object} oConfig Configuration object for AutoFill
|
15319 |
+
*/
|
15320 |
+
var AutoFill = function( dt, opts )
|
15321 |
+
{
|
15322 |
+
if ( ! DataTable.versionCheck || ! DataTable.versionCheck( '1.10.8' ) ) {
|
15323 |
+
throw( "Warning: AutoFill requires DataTables 1.10.8 or greater");
|
15324 |
+
}
|
15325 |
+
|
15326 |
+
// User and defaults configuration object
|
15327 |
+
this.c = $.extend( true, {},
|
15328 |
+
DataTable.defaults.autoFill,
|
15329 |
+
AutoFill.defaults,
|
15330 |
+
opts
|
15331 |
+
);
|
15332 |
+
|
15333 |
+
/**
|
15334 |
+
* @namespace Settings object which contains customisable information for AutoFill instance
|
15335 |
+
*/
|
15336 |
+
this.s = {
|
15337 |
+
/** @type {DataTable.Api} DataTables' API instance */
|
15338 |
+
dt: new DataTable.Api( dt ),
|
15339 |
+
|
15340 |
+
/** @type {String} Unique namespace for events attached to the document */
|
15341 |
+
namespace: '.autoFill'+(_instance++),
|
15342 |
+
|
15343 |
+
/** @type {Object} Cached dimension information for use in the mouse move event handler */
|
15344 |
+
scroll: {},
|
15345 |
+
|
15346 |
+
/** @type {integer} Interval object used for smooth scrolling */
|
15347 |
+
scrollInterval: null,
|
15348 |
+
|
15349 |
+
handle: {
|
15350 |
+
height: 0,
|
15351 |
+
width: 0
|
15352 |
+
},
|
15353 |
+
|
15354 |
+
/**
|
15355 |
+
* Enabled setting
|
15356 |
+
* @type {Boolean}
|
15357 |
+
*/
|
15358 |
+
enabled: false
|
15359 |
+
};
|
15360 |
+
|
15361 |
+
|
15362 |
+
/**
|
15363 |
+
* @namespace Common and useful DOM elements for the class instance
|
15364 |
+
*/
|
15365 |
+
this.dom = {
|
15366 |
+
/** @type {jQuery} AutoFill handle */
|
15367 |
+
handle: $('<div class="dt-autofill-handle"/>'),
|
15368 |
+
|
15369 |
+
/**
|
15370 |
+
* @type {Object} Selected cells outline - Need to use 4 elements,
|
15371 |
+
* otherwise the mouse over if you back into the selected rectangle
|
15372 |
+
* will be over that element, rather than the cells!
|
15373 |
+
*/
|
15374 |
+
select: {
|
15375 |
+
top: $('<div class="dt-autofill-select top"/>'),
|
15376 |
+
right: $('<div class="dt-autofill-select right"/>'),
|
15377 |
+
bottom: $('<div class="dt-autofill-select bottom"/>'),
|
15378 |
+
left: $('<div class="dt-autofill-select left"/>')
|
15379 |
+
},
|
15380 |
+
|
15381 |
+
/** @type {jQuery} Fill type chooser background */
|
15382 |
+
background: $('<div class="dt-autofill-background"/>'),
|
15383 |
+
|
15384 |
+
/** @type {jQuery} Fill type chooser */
|
15385 |
+
list: $('<div class="dt-autofill-list">'+this.s.dt.i18n('autoFill.info', '')+'<ul/></div>'),
|
15386 |
+
|
15387 |
+
/** @type {jQuery} DataTables scrolling container */
|
15388 |
+
dtScroll: null,
|
15389 |
+
|
15390 |
+
/** @type {jQuery} Offset parent element */
|
15391 |
+
offsetParent: null
|
15392 |
+
};
|
15393 |
+
|
15394 |
+
|
15395 |
+
/* Constructor logic */
|
15396 |
+
this._constructor();
|
15397 |
+
};
|
15398 |
+
|
15399 |
+
|
15400 |
+
|
15401 |
+
$.extend( AutoFill.prototype, {
|
15402 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
15403 |
+
* Public methods (exposed via the DataTables API below)
|
15404 |
+
*/
|
15405 |
+
enabled: function ()
|
15406 |
+
{
|
15407 |
+
return this.s.enabled;
|
15408 |
+
},
|
15409 |
+
|
15410 |
+
|
15411 |
+
enable: function ( flag )
|
15412 |
+
{
|
15413 |
+
var that = this;
|
15414 |
+
|
15415 |
+
if ( flag === false ) {
|
15416 |
+
return this.disable();
|
15417 |
+
}
|
15418 |
+
|
15419 |
+
this.s.enabled = true;
|
15420 |
+
|
15421 |
+
this._focusListener();
|
15422 |
+
|
15423 |
+
this.dom.handle.on( 'mousedown', function (e) {
|
15424 |
+
that._mousedown( e );
|
15425 |
+
return false;
|
15426 |
+
} );
|
15427 |
+
|
15428 |
+
return this;
|
15429 |
+
},
|
15430 |
+
|
15431 |
+
disable: function ()
|
15432 |
+
{
|
15433 |
+
this.s.enabled = false;
|
15434 |
+
|
15435 |
+
this._focusListenerRemove();
|
15436 |
+
|
15437 |
+
return this;
|
15438 |
+
},
|
15439 |
+
|
15440 |
+
|
15441 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
15442 |
+
* Constructor
|
15443 |
+
*/
|
15444 |
+
|
15445 |
+
/**
|
15446 |
+
* Initialise the RowReorder instance
|
15447 |
+
*
|
15448 |
+
* @private
|
15449 |
+
*/
|
15450 |
+
_constructor: function ()
|
15451 |
+
{
|
15452 |
+
var that = this;
|
15453 |
+
var dt = this.s.dt;
|
15454 |
+
var dtScroll = $('div.dataTables_scrollBody', this.s.dt.table().container());
|
15455 |
+
|
15456 |
+
// Make the instance accessible to the API
|
15457 |
+
dt.settings()[0].autoFill = this;
|
15458 |
+
|
15459 |
+
if ( dtScroll.length ) {
|
15460 |
+
this.dom.dtScroll = dtScroll;
|
15461 |
+
|
15462 |
+
// Need to scroll container to be the offset parent
|
15463 |
+
if ( dtScroll.css('position') === 'static' ) {
|
15464 |
+
dtScroll.css( 'position', 'relative' );
|
15465 |
+
}
|
15466 |
+
}
|
15467 |
+
|
15468 |
+
if ( this.c.enable !== false ) {
|
15469 |
+
this.enable();
|
15470 |
+
}
|
15471 |
+
|
15472 |
+
dt.on( 'destroy.autoFill', function () {
|
15473 |
+
that._focusListenerRemove();
|
15474 |
+
} );
|
15475 |
+
},
|
15476 |
+
|
15477 |
+
|
15478 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
15479 |
+
* Private methods
|
15480 |
+
*/
|
15481 |
+
|
15482 |
+
/**
|
15483 |
+
* Display the AutoFill drag handle by appending it to a table cell. This
|
15484 |
+
* is the opposite of the _detach method.
|
15485 |
+
*
|
15486 |
+
* @param {node} node TD/TH cell to insert the handle into
|
15487 |
+
* @private
|
15488 |
+
*/
|
15489 |
+
_attach: function ( node )
|
15490 |
+
{
|
15491 |
+
var dt = this.s.dt;
|
15492 |
+
var idx = dt.cell( node ).index();
|
15493 |
+
var handle = this.dom.handle;
|
15494 |
+
var handleDim = this.s.handle;
|
15495 |
+
|
15496 |
+
if ( ! idx || dt.columns( this.c.columns ).indexes().indexOf( idx.column ) === -1 ) {
|
15497 |
+
this._detach();
|
15498 |
+
return;
|
15499 |
+
}
|
15500 |
+
|
15501 |
+
if ( ! this.dom.offsetParent ) {
|
15502 |
+
// We attach to the table's offset parent
|
15503 |
+
this.dom.offsetParent = $( dt.table().node() ).offsetParent();
|
15504 |
+
}
|
15505 |
+
|
15506 |
+
if ( ! handleDim.height || ! handleDim.width ) {
|
15507 |
+
// Append to document so we can get its size. Not expecting it to
|
15508 |
+
// change during the life time of the page
|
15509 |
+
handle.appendTo( 'body' );
|
15510 |
+
handleDim.height = handle.outerHeight();
|
15511 |
+
handleDim.width = handle.outerWidth();
|
15512 |
+
}
|
15513 |
+
|
15514 |
+
// Might need to go through multiple offset parents
|
15515 |
+
var offset = this._getPosition( node, this.dom.offsetParent );
|
15516 |
+
|
15517 |
+
this.dom.attachedTo = node;
|
15518 |
+
handle
|
15519 |
+
.css( {
|
15520 |
+
top: offset.top + node.offsetHeight - handleDim.height,
|
15521 |
+
left: offset.left + node.offsetWidth - handleDim.width
|
15522 |
+
} )
|
15523 |
+
.appendTo( this.dom.offsetParent );
|
15524 |
+
},
|
15525 |
+
|
15526 |
+
|
15527 |
+
/**
|
15528 |
+
* Determine can the fill type should be. This can be automatic, or ask the
|
15529 |
+
* end user.
|
15530 |
+
*
|
15531 |
+
* @param {array} cells Information about the selected cells from the key
|
15532 |
+
* up function
|
15533 |
+
* @private
|
15534 |
+
*/
|
15535 |
+
_actionSelector: function ( cells )
|
15536 |
+
{
|
15537 |
+
var that = this;
|
15538 |
+
var dt = this.s.dt;
|
15539 |
+
var actions = AutoFill.actions;
|
15540 |
+
var available = [];
|
15541 |
+
|
15542 |
+
// "Ask" each plug-in if it wants to handle this data
|
15543 |
+
$.each( actions, function ( key, action ) {
|
15544 |
+
if ( action.available( dt, cells ) ) {
|
15545 |
+
available.push( key );
|
15546 |
+
}
|
15547 |
+
} );
|
15548 |
+
|
15549 |
+
if ( available.length === 1 && this.c.alwaysAsk === false ) {
|
15550 |
+
// Only one action available - enact it immediately
|
15551 |
+
var result = actions[ available[0] ].execute( dt, cells );
|
15552 |
+
this._update( result, cells );
|
15553 |
+
}
|
15554 |
+
else {
|
15555 |
+
// Multiple actions available - ask the end user what they want to do
|
15556 |
+
var list = this.dom.list.children('ul').empty();
|
15557 |
+
|
15558 |
+
// Add a cancel option
|
15559 |
+
available.push( 'cancel' );
|
15560 |
+
|
15561 |
+
$.each( available, function ( i, name ) {
|
15562 |
+
list.append( $('<li/>')
|
15563 |
+
.append(
|
15564 |
+
'<div class="dt-autofill-question">'+
|
15565 |
+
actions[ name ].option( dt, cells )+
|
15566 |
+
'<div>'
|
15567 |
+
)
|
15568 |
+
.append( $('<div class="dt-autofill-button">' )
|
15569 |
+
.append( $('<button class="'+AutoFill.classes.btn+'">'+dt.i18n('autoFill.button', '>')+'</button>')
|
15570 |
+
.on( 'click', function () {
|
15571 |
+
var result = actions[ name ].execute(
|
15572 |
+
dt, cells, $(this).closest('li')
|
15573 |
+
);
|
15574 |
+
that._update( result, cells );
|
15575 |
+
|
15576 |
+
that.dom.background.remove();
|
15577 |
+
that.dom.list.remove();
|
15578 |
+
} )
|
15579 |
+
)
|
15580 |
+
)
|
15581 |
+
);
|
15582 |
+
} );
|
15583 |
+
|
15584 |
+
this.dom.background.appendTo( 'body' );
|
15585 |
+
this.dom.list.appendTo( 'body' );
|
15586 |
+
|
15587 |
+
this.dom.list.css( 'margin-top', this.dom.list.outerHeight()/2 * -1 );
|
15588 |
+
}
|
15589 |
+
},
|
15590 |
+
|
15591 |
+
|
15592 |
+
/**
|
15593 |
+
* Remove the AutoFill handle from the document
|
15594 |
+
*
|
15595 |
+
* @private
|
15596 |
+
*/
|
15597 |
+
_detach: function ()
|
15598 |
+
{
|
15599 |
+
this.dom.attachedTo = null;
|
15600 |
+
this.dom.handle.detach();
|
15601 |
+
},
|
15602 |
+
|
15603 |
+
|
15604 |
+
/**
|
15605 |
+
* Draw the selection outline by calculating the range between the start
|
15606 |
+
* and end cells, then placing the highlighting elements to draw a rectangle
|
15607 |
+
*
|
15608 |
+
* @param {node} target End cell
|
15609 |
+
* @param {object} e Originating event
|
15610 |
+
* @private
|
15611 |
+
*/
|
15612 |
+
_drawSelection: function ( target, e )
|
15613 |
+
{
|
15614 |
+
// Calculate boundary for start cell to this one
|
15615 |
+
var dt = this.s.dt;
|
15616 |
+
var start = this.s.start;
|
15617 |
+
var startCell = $(this.dom.start);
|
15618 |
+
var endCell = $(target);
|
15619 |
+
var end = {
|
15620 |
+
row: dt.rows( { page: 'current' } ).nodes().indexOf( endCell.parent()[0] ),
|
15621 |
+
column: endCell.index()
|
15622 |
+
};
|
15623 |
+
var colIndx = dt.column.index( 'toData', end.column );
|
15624 |
+
|
15625 |
+
// Be sure that is a DataTables controlled cell
|
15626 |
+
if ( ! dt.cell( endCell ).any() ) {
|
15627 |
+
return;
|
15628 |
+
}
|
15629 |
+
|
15630 |
+
// if target is not in the columns available - do nothing
|
15631 |
+
if ( dt.columns( this.c.columns ).indexes().indexOf( colIndx ) === -1 ) {
|
15632 |
+
return;
|
15633 |
+
}
|
15634 |
+
|
15635 |
+
this.s.end = end;
|
15636 |
+
|
15637 |
+
var top, bottom, left, right, height, width;
|
15638 |
+
|
15639 |
+
top = start.row < end.row ? startCell : endCell;
|
15640 |
+
bottom = start.row < end.row ? endCell : startCell;
|
15641 |
+
left = start.column < end.column ? startCell : endCell;
|
15642 |
+
right = start.column < end.column ? endCell : startCell;
|
15643 |
+
|
15644 |
+
top = this._getPosition( top ).top;
|
15645 |
+
left = this._getPosition( left ).left;
|
15646 |
+
height = this._getPosition( bottom ).top + bottom.outerHeight() - top;
|
15647 |
+
width = this._getPosition( right ).left + right.outerWidth() - left;
|
15648 |
+
|
15649 |
+
var select = this.dom.select;
|
15650 |
+
select.top.css( {
|
15651 |
+
top: top,
|
15652 |
+
left: left,
|
15653 |
+
width: width
|
15654 |
+
} );
|
15655 |
+
|
15656 |
+
select.left.css( {
|
15657 |
+
top: top,
|
15658 |
+
left: left,
|
15659 |
+
height: height
|
15660 |
+
} );
|
15661 |
+
|
15662 |
+
select.bottom.css( {
|
15663 |
+
top: top + height,
|
15664 |
+
left: left,
|
15665 |
+
width: width
|
15666 |
+
} );
|
15667 |
+
|
15668 |
+
select.right.css( {
|
15669 |
+
top: top,
|
15670 |
+
left: left + width,
|
15671 |
+
height: height
|
15672 |
+
} );
|
15673 |
+
},
|
15674 |
+
|
15675 |
+
|
15676 |
+
/**
|
15677 |
+
* Use the Editor API to perform an update based on the new data for the
|
15678 |
+
* cells
|
15679 |
+
*
|
15680 |
+
* @param {array} cells Information about the selected cells from the key
|
15681 |
+
* up function
|
15682 |
+
* @private
|
15683 |
+
*/
|
15684 |
+
_editor: function ( cells )
|
15685 |
+
{
|
15686 |
+
var dt = this.s.dt;
|
15687 |
+
var editor = this.c.editor;
|
15688 |
+
|
15689 |
+
if ( ! editor ) {
|
15690 |
+
return;
|
15691 |
+
}
|
15692 |
+
|
15693 |
+
// Build the object structure for Editor's multi-row editing
|
15694 |
+
var idValues = {};
|
15695 |
+
var nodes = [];
|
15696 |
+
var fields = editor.fields();
|
15697 |
+
|
15698 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
15699 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
15700 |
+
var cell = cells[i][j];
|
15701 |
+
|
15702 |
+
// Determine the field name for the cell being edited
|
15703 |
+
var col = dt.settings()[0].aoColumns[ cell.index.column ];
|
15704 |
+
var fieldName = col.editField;
|
15705 |
+
|
15706 |
+
if ( fieldName === undefined ) {
|
15707 |
+
var dataSrc = col.mData;
|
15708 |
+
|
15709 |
+
// dataSrc is the `field.data` property, but we need to set
|
15710 |
+
// using the field name, so we need to translate from the
|
15711 |
+
// data to the name
|
15712 |
+
for ( var k=0, ken=fields.length ; k<ken ; k++ ) {
|
15713 |
+
var field = editor.field( fields[k] );
|
15714 |
+
|
15715 |
+
if ( field.dataSrc() === dataSrc ) {
|
15716 |
+
fieldName = field.name();
|
15717 |
+
break;
|
15718 |
+
}
|
15719 |
+
}
|
15720 |
+
}
|
15721 |
+
|
15722 |
+
if ( ! fieldName ) {
|
15723 |
+
throw 'Could not automatically determine field data. '+
|
15724 |
+
'Please see https://datatables.net/tn/11';
|
15725 |
+
}
|
15726 |
+
|
15727 |
+
if ( ! idValues[ fieldName ] ) {
|
15728 |
+
idValues[ fieldName ] = {};
|
15729 |
+
}
|
15730 |
+
|
15731 |
+
var id = dt.row( cell.index.row ).id();
|
15732 |
+
idValues[ fieldName ][ id ] = cell.set;
|
15733 |
+
|
15734 |
+
// Keep a list of cells so we can activate the bubble editing
|
15735 |
+
// with them
|
15736 |
+
nodes.push( cell.index );
|
15737 |
+
}
|
15738 |
+
}
|
15739 |
+
|
15740 |
+
// Perform the edit using bubble editing as it allows us to specify
|
15741 |
+
// the cells to be edited, rather than using full rows
|
15742 |
+
editor
|
15743 |
+
.bubble( nodes, false )
|
15744 |
+
.multiSet( idValues )
|
15745 |
+
.submit();
|
15746 |
+
},
|
15747 |
+
|
15748 |
+
|
15749 |
+
/**
|
15750 |
+
* Emit an event on the DataTable for listeners
|
15751 |
+
*
|
15752 |
+
* @param {string} name Event name
|
15753 |
+
* @param {array} args Event arguments
|
15754 |
+
* @private
|
15755 |
+
*/
|
15756 |
+
_emitEvent: function ( name, args )
|
15757 |
+
{
|
15758 |
+
this.s.dt.iterator( 'table', function ( ctx, i ) {
|
15759 |
+
$(ctx.nTable).triggerHandler( name+'.dt', args );
|
15760 |
+
} );
|
15761 |
+
},
|
15762 |
+
|
15763 |
+
|
15764 |
+
/**
|
15765 |
+
* Attach suitable listeners (based on the configuration) that will attach
|
15766 |
+
* and detach the AutoFill handle in the document.
|
15767 |
+
*
|
15768 |
+
* @private
|
15769 |
+
*/
|
15770 |
+
_focusListener: function ()
|
15771 |
+
{
|
15772 |
+
var that = this;
|
15773 |
+
var dt = this.s.dt;
|
15774 |
+
var namespace = this.s.namespace;
|
15775 |
+
var focus = this.c.focus !== null ?
|
15776 |
+
this.c.focus :
|
15777 |
+
dt.init().keys || dt.settings()[0].keytable ?
|
15778 |
+
'focus' :
|
15779 |
+
'hover';
|
15780 |
+
|
15781 |
+
// All event listeners attached here are removed in the `destroy`
|
15782 |
+
// callback in the constructor
|
15783 |
+
if ( focus === 'focus' ) {
|
15784 |
+
dt
|
15785 |
+
.on( 'key-focus.autoFill', function ( e, dt, cell ) {
|
15786 |
+
that._attach( cell.node() );
|
15787 |
+
} )
|
15788 |
+
.on( 'key-blur.autoFill', function ( e, dt, cell ) {
|
15789 |
+
that._detach();
|
15790 |
+
} );
|
15791 |
+
}
|
15792 |
+
else if ( focus === 'click' ) {
|
15793 |
+
$(dt.table().body()).on( 'click'+namespace, 'td, th', function (e) {
|
15794 |
+
that._attach( this );
|
15795 |
+
} );
|
15796 |
+
|
15797 |
+
$(document.body).on( 'click'+namespace, function (e) {
|
15798 |
+
if ( ! $(e.target).parents().filter( dt.table().body() ).length ) {
|
15799 |
+
that._detach();
|
15800 |
+
}
|
15801 |
+
} );
|
15802 |
+
}
|
15803 |
+
else {
|
15804 |
+
$(dt.table().body())
|
15805 |
+
.on( 'mouseenter'+namespace, 'td, th', function (e) {
|
15806 |
+
that._attach( this );
|
15807 |
+
} )
|
15808 |
+
.on( 'mouseleave'+namespace, function (e) {
|
15809 |
+
if ( $(e.relatedTarget).hasClass('dt-autofill-handle') ) {
|
15810 |
+
return;
|
15811 |
+
}
|
15812 |
+
|
15813 |
+
that._detach();
|
15814 |
+
} );
|
15815 |
+
}
|
15816 |
+
},
|
15817 |
+
|
15818 |
+
|
15819 |
+
_focusListenerRemove: function ()
|
15820 |
+
{
|
15821 |
+
var dt = this.s.dt;
|
15822 |
+
|
15823 |
+
dt.off( '.autoFill' );
|
15824 |
+
$(dt.table().body()).off( this.s.namespace );
|
15825 |
+
$(document.body).off( this.s.namespace );
|
15826 |
+
},
|
15827 |
+
|
15828 |
+
|
15829 |
+
/**
|
15830 |
+
* Get the position of a node, relative to another, including any scrolling
|
15831 |
+
* offsets.
|
15832 |
+
* @param {Node} node Node to get the position of
|
15833 |
+
* @param {jQuery} targetParent Node to use as the parent
|
15834 |
+
* @return {object} Offset calculation
|
15835 |
+
* @private
|
15836 |
+
*/
|
15837 |
+
_getPosition: function ( node, targetParent )
|
15838 |
+
{
|
15839 |
+
var
|
15840 |
+
currNode = $(node),
|
15841 |
+
currOffsetParent,
|
15842 |
+
position,
|
15843 |
+
top = 0,
|
15844 |
+
left = 0;
|
15845 |
+
|
15846 |
+
if ( ! targetParent ) {
|
15847 |
+
targetParent = $( this.s.dt.table().node() ).offsetParent();
|
15848 |
+
}
|
15849 |
+
|
15850 |
+
do {
|
15851 |
+
position = currNode.position();
|
15852 |
+
currOffsetParent = currNode.offsetParent();
|
15853 |
+
|
15854 |
+
top += position.top + currOffsetParent.scrollTop();
|
15855 |
+
left += position.left + currOffsetParent.scrollLeft();
|
15856 |
+
|
15857 |
+
// Emergency fall back. Shouldn't happen, but just in case!
|
15858 |
+
if ( currNode.get(0).nodeName.toLowerCase() === 'body' ) {
|
15859 |
+
break;
|
15860 |
+
}
|
15861 |
+
|
15862 |
+
currNode = currOffsetParent; // for next loop
|
15863 |
+
}
|
15864 |
+
while ( currOffsetParent.get(0) !== targetParent.get(0) )
|
15865 |
+
|
15866 |
+
return {
|
15867 |
+
top: top,
|
15868 |
+
left: left
|
15869 |
+
};
|
15870 |
+
},
|
15871 |
+
|
15872 |
+
|
15873 |
+
/**
|
15874 |
+
* Start mouse drag - selects the start cell
|
15875 |
+
*
|
15876 |
+
* @param {object} e Mouse down event
|
15877 |
+
* @private
|
15878 |
+
*/
|
15879 |
+
_mousedown: function ( e )
|
15880 |
+
{
|
15881 |
+
var that = this;
|
15882 |
+
var dt = this.s.dt;
|
15883 |
+
|
15884 |
+
this.dom.start = this.dom.attachedTo;
|
15885 |
+
this.s.start = {
|
15886 |
+
row: dt.rows( { page: 'current' } ).nodes().indexOf( $(this.dom.start).parent()[0] ),
|
15887 |
+
column: $(this.dom.start).index()
|
15888 |
+
};
|
15889 |
+
|
15890 |
+
$(document.body)
|
15891 |
+
.on( 'mousemove.autoFill', function (e) {
|
15892 |
+
that._mousemove( e );
|
15893 |
+
} )
|
15894 |
+
.on( 'mouseup.autoFill', function (e) {
|
15895 |
+
that._mouseup( e );
|
15896 |
+
} );
|
15897 |
+
|
15898 |
+
var select = this.dom.select;
|
15899 |
+
var offsetParent = $( dt.table().node() ).offsetParent();
|
15900 |
+
select.top.appendTo( offsetParent );
|
15901 |
+
select.left.appendTo( offsetParent );
|
15902 |
+
select.right.appendTo( offsetParent );
|
15903 |
+
select.bottom.appendTo( offsetParent );
|
15904 |
+
|
15905 |
+
this._drawSelection( this.dom.start, e );
|
15906 |
+
|
15907 |
+
this.dom.handle.css( 'display', 'none' );
|
15908 |
+
|
15909 |
+
// Cache scrolling information so mouse move doesn't need to read.
|
15910 |
+
// This assumes that the window and DT scroller will not change size
|
15911 |
+
// during an AutoFill drag, which I think is a fair assumption
|
15912 |
+
var scrollWrapper = this.dom.dtScroll;
|
15913 |
+
this.s.scroll = {
|
15914 |
+
windowHeight: $(window).height(),
|
15915 |
+
windowWidth: $(window).width(),
|
15916 |
+
dtTop: scrollWrapper ? scrollWrapper.offset().top : null,
|
15917 |
+
dtLeft: scrollWrapper ? scrollWrapper.offset().left : null,
|
15918 |
+
dtHeight: scrollWrapper ? scrollWrapper.outerHeight() : null,
|
15919 |
+
dtWidth: scrollWrapper ? scrollWrapper.outerWidth() : null
|
15920 |
+
};
|
15921 |
+
},
|
15922 |
+
|
15923 |
+
|
15924 |
+
/**
|
15925 |
+
* Mouse drag - selects the end cell and update the selection display for
|
15926 |
+
* the end user
|
15927 |
+
*
|
15928 |
+
* @param {object} e Mouse move event
|
15929 |
+
* @private
|
15930 |
+
*/
|
15931 |
+
_mousemove: function ( e )
|
15932 |
+
{
|
15933 |
+
var that = this;
|
15934 |
+
var dt = this.s.dt;
|
15935 |
+
var name = e.target.nodeName.toLowerCase();
|
15936 |
+
if ( name !== 'td' && name !== 'th' ) {
|
15937 |
+
return;
|
15938 |
+
}
|
15939 |
+
|
15940 |
+
this._drawSelection( e.target, e );
|
15941 |
+
this._shiftScroll( e );
|
15942 |
+
},
|
15943 |
+
|
15944 |
+
|
15945 |
+
/**
|
15946 |
+
* End mouse drag - perform the update actions
|
15947 |
+
*
|
15948 |
+
* @param {object} e Mouse up event
|
15949 |
+
* @private
|
15950 |
+
*/
|
15951 |
+
_mouseup: function ( e )
|
15952 |
+
{
|
15953 |
+
$(document.body).off( '.autoFill' );
|
15954 |
+
|
15955 |
+
var dt = this.s.dt;
|
15956 |
+
var select = this.dom.select;
|
15957 |
+
select.top.remove();
|
15958 |
+
select.left.remove();
|
15959 |
+
select.right.remove();
|
15960 |
+
select.bottom.remove();
|
15961 |
+
|
15962 |
+
this.dom.handle.css( 'display', 'block' );
|
15963 |
+
|
15964 |
+
// Display complete - now do something useful with the selection!
|
15965 |
+
var start = this.s.start;
|
15966 |
+
var end = this.s.end;
|
15967 |
+
|
15968 |
+
// Haven't selected multiple cells, so nothing to do
|
15969 |
+
if ( start.row === end.row && start.column === end.column ) {
|
15970 |
+
return;
|
15971 |
+
}
|
15972 |
+
|
15973 |
+
// Build a matrix representation of the selected rows
|
15974 |
+
var rows = this._range( start.row, end.row );
|
15975 |
+
var columns = this._range( start.column, end.column );
|
15976 |
+
var selected = [];
|
15977 |
+
var dtSettings = dt.settings()[0];
|
15978 |
+
var dtColumns = dtSettings.aoColumns;
|
15979 |
+
|
15980 |
+
// Can't use Array.prototype.map as IE8 doesn't support it
|
15981 |
+
// Can't use $.map as jQuery flattens 2D arrays
|
15982 |
+
// Need to use a good old fashioned for loop
|
15983 |
+
for ( var rowIdx=0 ; rowIdx<rows.length ; rowIdx++ ) {
|
15984 |
+
selected.push(
|
15985 |
+
$.map( columns, function (column) {
|
15986 |
+
var cell = dt.cell( ':eq('+rows[rowIdx]+')', column+':visible', {page:'current'} );
|
15987 |
+
var data = cell.data();
|
15988 |
+
var cellIndex = cell.index();
|
15989 |
+
var editField = dtColumns[ cellIndex.column ].editField;
|
15990 |
+
|
15991 |
+
if ( editField !== undefined ) {
|
15992 |
+
data = dtSettings.oApi._fnGetObjectDataFn( editField )( dt.row( cellIndex.row ).data() );
|
15993 |
+
}
|
15994 |
+
|
15995 |
+
return {
|
15996 |
+
cell: cell,
|
15997 |
+
data: data,
|
15998 |
+
label: cell.data(),
|
15999 |
+
index: cellIndex
|
16000 |
+
};
|
16001 |
+
} )
|
16002 |
+
);
|
16003 |
+
}
|
16004 |
+
|
16005 |
+
this._actionSelector( selected );
|
16006 |
+
|
16007 |
+
// Stop shiftScroll
|
16008 |
+
clearInterval( this.s.scrollInterval );
|
16009 |
+
this.s.scrollInterval = null;
|
16010 |
+
},
|
16011 |
+
|
16012 |
+
|
16013 |
+
/**
|
16014 |
+
* Create an array with a range of numbers defined by the start and end
|
16015 |
+
* parameters passed in (inclusive!).
|
16016 |
+
*
|
16017 |
+
* @param {integer} start Start
|
16018 |
+
* @param {integer} end End
|
16019 |
+
* @private
|
16020 |
+
*/
|
16021 |
+
_range: function ( start, end )
|
16022 |
+
{
|
16023 |
+
var out = [];
|
16024 |
+
var i;
|
16025 |
+
|
16026 |
+
if ( start <= end ) {
|
16027 |
+
for ( i=start ; i<=end ; i++ ) {
|
16028 |
+
out.push( i );
|
16029 |
+
}
|
16030 |
+
}
|
16031 |
+
else {
|
16032 |
+
for ( i=start ; i>=end ; i-- ) {
|
16033 |
+
out.push( i );
|
16034 |
+
}
|
16035 |
+
}
|
16036 |
+
|
16037 |
+
return out;
|
16038 |
+
},
|
16039 |
+
|
16040 |
+
|
16041 |
+
/**
|
16042 |
+
* Move the window and DataTables scrolling during a drag to scroll new
|
16043 |
+
* content into view. This is done by proximity to the edge of the scrolling
|
16044 |
+
* container of the mouse - for example near the top edge of the window
|
16045 |
+
* should scroll up. This is a little complicated as there are two elements
|
16046 |
+
* that can be scrolled - the window and the DataTables scrolling view port
|
16047 |
+
* (if scrollX and / or scrollY is enabled).
|
16048 |
+
*
|
16049 |
+
* @param {object} e Mouse move event object
|
16050 |
+
* @private
|
16051 |
+
*/
|
16052 |
+
_shiftScroll: function ( e )
|
16053 |
+
{
|
16054 |
+
var that = this;
|
16055 |
+
var dt = this.s.dt;
|
16056 |
+
var scroll = this.s.scroll;
|
16057 |
+
var runInterval = false;
|
16058 |
+
var scrollSpeed = 5;
|
16059 |
+
var buffer = 65;
|
16060 |
+
var
|
16061 |
+
windowY = e.pageY - document.body.scrollTop,
|
16062 |
+
windowX = e.pageX - document.body.scrollLeft,
|
16063 |
+
windowVert, windowHoriz,
|
16064 |
+
dtVert, dtHoriz;
|
16065 |
+
|
16066 |
+
// Window calculations - based on the mouse position in the window,
|
16067 |
+
// regardless of scrolling
|
16068 |
+
if ( windowY < buffer ) {
|
16069 |
+
windowVert = scrollSpeed * -1;
|
16070 |
+
}
|
16071 |
+
else if ( windowY > scroll.windowHeight - buffer ) {
|
16072 |
+
windowVert = scrollSpeed;
|
16073 |
+
}
|
16074 |
+
|
16075 |
+
if ( windowX < buffer ) {
|
16076 |
+
windowHoriz = scrollSpeed * -1;
|
16077 |
+
}
|
16078 |
+
else if ( windowX > scroll.windowWidth - buffer ) {
|
16079 |
+
windowHoriz = scrollSpeed;
|
16080 |
+
}
|
16081 |
+
|
16082 |
+
// DataTables scrolling calculations - based on the table's position in
|
16083 |
+
// the document and the mouse position on the page
|
16084 |
+
if ( scroll.dtTop !== null && e.pageY < scroll.dtTop + buffer ) {
|
16085 |
+
dtVert = scrollSpeed * -1;
|
16086 |
+
}
|
16087 |
+
else if ( scroll.dtTop !== null && e.pageY > scroll.dtTop + scroll.dtHeight - buffer ) {
|
16088 |
+
dtVert = scrollSpeed;
|
16089 |
+
}
|
16090 |
+
|
16091 |
+
if ( scroll.dtLeft !== null && e.pageX < scroll.dtLeft + buffer ) {
|
16092 |
+
dtHoriz = scrollSpeed * -1;
|
16093 |
+
}
|
16094 |
+
else if ( scroll.dtLeft !== null && e.pageX > scroll.dtLeft + scroll.dtWidth - buffer ) {
|
16095 |
+
dtHoriz = scrollSpeed;
|
16096 |
+
}
|
16097 |
+
|
16098 |
+
// This is where it gets interesting. We want to continue scrolling
|
16099 |
+
// without requiring a mouse move, so we need an interval to be
|
16100 |
+
// triggered. The interval should continue until it is no longer needed,
|
16101 |
+
// but it must also use the latest scroll commands (for example consider
|
16102 |
+
// that the mouse might move from scrolling up to scrolling left, all
|
16103 |
+
// with the same interval running. We use the `scroll` object to "pass"
|
16104 |
+
// this information to the interval. Can't use local variables as they
|
16105 |
+
// wouldn't be the ones that are used by an already existing interval!
|
16106 |
+
if ( windowVert || windowHoriz || dtVert || dtHoriz ) {
|
16107 |
+
scroll.windowVert = windowVert;
|
16108 |
+
scroll.windowHoriz = windowHoriz;
|
16109 |
+
scroll.dtVert = dtVert;
|
16110 |
+
scroll.dtHoriz = dtHoriz;
|
16111 |
+
runInterval = true;
|
16112 |
+
}
|
16113 |
+
else if ( this.s.scrollInterval ) {
|
16114 |
+
// Don't need to scroll - remove any existing timer
|
16115 |
+
clearInterval( this.s.scrollInterval );
|
16116 |
+
this.s.scrollInterval = null;
|
16117 |
+
}
|
16118 |
+
|
16119 |
+
// If we need to run the interval to scroll and there is no existing
|
16120 |
+
// interval (if there is an existing one, it will continue to run)
|
16121 |
+
if ( ! this.s.scrollInterval && runInterval ) {
|
16122 |
+
this.s.scrollInterval = setInterval( function () {
|
16123 |
+
// Don't need to worry about setting scroll <0 or beyond the
|
16124 |
+
// scroll bound as the browser will just reject that.
|
16125 |
+
if ( scroll.windowVert ) {
|
16126 |
+
document.body.scrollTop += scroll.windowVert;
|
16127 |
+
}
|
16128 |
+
if ( scroll.windowHoriz ) {
|
16129 |
+
document.body.scrollLeft += scroll.windowHoriz;
|
16130 |
+
}
|
16131 |
+
|
16132 |
+
// DataTables scrolling
|
16133 |
+
if ( scroll.dtVert || scroll.dtHoriz ) {
|
16134 |
+
var scroller = that.dom.dtScroll[0];
|
16135 |
+
|
16136 |
+
if ( scroll.dtVert ) {
|
16137 |
+
scroller.scrollTop += scroll.dtVert;
|
16138 |
+
}
|
16139 |
+
if ( scroll.dtHoriz ) {
|
16140 |
+
scroller.scrollLeft += scroll.dtHoriz;
|
16141 |
+
}
|
16142 |
+
}
|
16143 |
+
}, 20 );
|
16144 |
+
}
|
16145 |
+
},
|
16146 |
+
|
16147 |
+
|
16148 |
+
/**
|
16149 |
+
* Update the DataTable after the user has selected what they want to do
|
16150 |
+
*
|
16151 |
+
* @param {false|undefined} result Return from the `execute` method - can
|
16152 |
+
* be false internally to do nothing. This is not documented for plug-ins
|
16153 |
+
* and is used only by the cancel option.
|
16154 |
+
* @param {array} cells Information about the selected cells from the key
|
16155 |
+
* up function, argumented with the set values
|
16156 |
+
* @private
|
16157 |
+
*/
|
16158 |
+
_update: function ( result, cells )
|
16159 |
+
{
|
16160 |
+
// Do nothing on `false` return from an execute function
|
16161 |
+
if ( result === false ) {
|
16162 |
+
return;
|
16163 |
+
}
|
16164 |
+
|
16165 |
+
var dt = this.s.dt;
|
16166 |
+
var cell;
|
16167 |
+
|
16168 |
+
// Potentially allow modifications to the cells matrix
|
16169 |
+
this._emitEvent( 'preAutoFill', [ dt, cells ] );
|
16170 |
+
|
16171 |
+
this._editor( cells );
|
16172 |
+
|
16173 |
+
// Automatic updates are not performed if `update` is null and the
|
16174 |
+
// `editor` parameter is passed in - the reason being that Editor will
|
16175 |
+
// update the data once submitted
|
16176 |
+
var update = this.c.update !== null ?
|
16177 |
+
this.c.update :
|
16178 |
+
this.c.editor ?
|
16179 |
+
false :
|
16180 |
+
true;
|
16181 |
+
|
16182 |
+
if ( update ) {
|
16183 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
16184 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
16185 |
+
cell = cells[i][j];
|
16186 |
+
|
16187 |
+
cell.cell.data( cell.set );
|
16188 |
+
}
|
16189 |
+
}
|
16190 |
+
|
16191 |
+
dt.draw(false);
|
16192 |
+
}
|
16193 |
+
|
16194 |
+
this._emitEvent( 'autoFill', [ dt, cells ] );
|
16195 |
+
}
|
16196 |
+
} );
|
16197 |
+
|
16198 |
+
|
16199 |
+
/**
|
16200 |
+
* AutoFill actions. The options here determine how AutoFill will fill the data
|
16201 |
+
* in the table when the user has selected a range of cells. Please see the
|
16202 |
+
* documentation on the DataTables site for full details on how to create plug-
|
16203 |
+
* ins.
|
16204 |
+
*
|
16205 |
+
* @type {Object}
|
16206 |
+
*/
|
16207 |
+
AutoFill.actions = {
|
16208 |
+
increment: {
|
16209 |
+
available: function ( dt, cells ) {
|
16210 |
+
return $.isNumeric( cells[0][0].label );
|
16211 |
+
},
|
16212 |
+
|
16213 |
+
option: function ( dt, cells ) {
|
16214 |
+
return dt.i18n(
|
16215 |
+
'autoFill.increment',
|
16216 |
+
'Increment / decrement each cell by: <input type="number" value="1">'
|
16217 |
+
);
|
16218 |
+
},
|
16219 |
+
|
16220 |
+
execute: function ( dt, cells, node ) {
|
16221 |
+
var value = cells[0][0].data * 1;
|
16222 |
+
var increment = $('input', node).val() * 1;
|
16223 |
+
|
16224 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
16225 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
16226 |
+
cells[i][j].set = value;
|
16227 |
+
|
16228 |
+
value += increment;
|
16229 |
+
}
|
16230 |
+
}
|
16231 |
+
}
|
16232 |
+
},
|
16233 |
+
|
16234 |
+
fill: {
|
16235 |
+
available: function ( dt, cells ) {
|
16236 |
+
return true;
|
16237 |
+
},
|
16238 |
+
|
16239 |
+
option: function ( dt, cells ) {
|
16240 |
+
return dt.i18n('autoFill.fill', 'Fill all cells with <i>'+cells[0][0].label+'</i>' );
|
16241 |
+
},
|
16242 |
+
|
16243 |
+
execute: function ( dt, cells, node ) {
|
16244 |
+
var value = cells[0][0].data;
|
16245 |
+
|
16246 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
16247 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
16248 |
+
cells[i][j].set = value;
|
16249 |
+
}
|
16250 |
+
}
|
16251 |
+
}
|
16252 |
+
},
|
16253 |
+
|
16254 |
+
fillHorizontal: {
|
16255 |
+
available: function ( dt, cells ) {
|
16256 |
+
return cells.length > 1 && cells[0].length > 1;
|
16257 |
+
},
|
16258 |
+
|
16259 |
+
option: function ( dt, cells ) {
|
16260 |
+
return dt.i18n('autoFill.fillHorizontal', 'Fill cells horizontally' );
|
16261 |
+
},
|
16262 |
+
|
16263 |
+
execute: function ( dt, cells, node ) {
|
16264 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
16265 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
16266 |
+
cells[i][j].set = cells[i][0].data;
|
16267 |
+
}
|
16268 |
+
}
|
16269 |
+
}
|
16270 |
+
},
|
16271 |
+
|
16272 |
+
fillVertical: {
|
16273 |
+
available: function ( dt, cells ) {
|
16274 |
+
return cells.length > 1 && cells[0].length > 1;
|
16275 |
+
},
|
16276 |
+
|
16277 |
+
option: function ( dt, cells ) {
|
16278 |
+
return dt.i18n('autoFill.fillVertical', 'Fill cells vertically' );
|
16279 |
+
},
|
16280 |
+
|
16281 |
+
execute: function ( dt, cells, node ) {
|
16282 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
16283 |
+
for ( var j=0, jen=cells[i].length ; j<jen ; j++ ) {
|
16284 |
+
cells[i][j].set = cells[0][j].data;
|
16285 |
+
}
|
16286 |
+
}
|
16287 |
+
}
|
16288 |
+
},
|
16289 |
+
|
16290 |
+
// Special type that does not make itself available, but is added
|
16291 |
+
// automatically by AutoFill if a multi-choice list is shown. This allows
|
16292 |
+
// sensible code reuse
|
16293 |
+
cancel: {
|
16294 |
+
available: function () {
|
16295 |
+
return false;
|
16296 |
+
},
|
16297 |
+
|
16298 |
+
option: function ( dt ) {
|
16299 |
+
return dt.i18n('autoFill.cancel', 'Cancel' );
|
16300 |
+
},
|
16301 |
+
|
16302 |
+
execute: function () {
|
16303 |
+
return false;
|
16304 |
+
}
|
16305 |
+
}
|
16306 |
+
};
|
16307 |
+
|
16308 |
+
|
16309 |
+
/**
|
16310 |
+
* AutoFill version
|
16311 |
+
*
|
16312 |
+
* @static
|
16313 |
+
* @type String
|
16314 |
+
*/
|
16315 |
+
AutoFill.version = '2.2.2';
|
16316 |
+
|
16317 |
+
|
16318 |
+
/**
|
16319 |
+
* AutoFill defaults
|
16320 |
+
*
|
16321 |
+
* @namespace
|
16322 |
+
*/
|
16323 |
+
AutoFill.defaults = {
|
16324 |
+
/** @type {Boolean} Ask user what they want to do, even for a single option */
|
16325 |
+
alwaysAsk: false,
|
16326 |
+
|
16327 |
+
/** @type {string|null} What will trigger a focus */
|
16328 |
+
focus: null, // focus, click, hover
|
16329 |
+
|
16330 |
+
/** @type {column-selector} Columns to provide auto fill for */
|
16331 |
+
columns: '', // all
|
16332 |
+
|
16333 |
+
/** @type {Boolean} Enable AutoFill on load */
|
16334 |
+
enable: true,
|
16335 |
+
|
16336 |
+
/** @type {boolean|null} Update the cells after a drag */
|
16337 |
+
update: null, // false is editor given, true otherwise
|
16338 |
+
|
16339 |
+
/** @type {DataTable.Editor} Editor instance for automatic submission */
|
16340 |
+
editor: null
|
16341 |
+
};
|
16342 |
+
|
16343 |
+
|
16344 |
+
/**
|
16345 |
+
* Classes used by AutoFill that are configurable
|
16346 |
+
*
|
16347 |
+
* @namespace
|
16348 |
+
*/
|
16349 |
+
AutoFill.classes = {
|
16350 |
+
/** @type {String} Class used by the selection button */
|
16351 |
+
btn: 'btn'
|
16352 |
+
};
|
16353 |
+
|
16354 |
+
|
16355 |
+
/*
|
16356 |
+
* API
|
16357 |
+
*/
|
16358 |
+
var Api = $.fn.dataTable.Api;
|
16359 |
+
|
16360 |
+
// Doesn't do anything - Not documented
|
16361 |
+
Api.register( 'autoFill()', function () {
|
16362 |
+
return this;
|
16363 |
+
} );
|
16364 |
+
|
16365 |
+
Api.register( 'autoFill().enabled()', function () {
|
16366 |
+
var ctx = this.context[0];
|
16367 |
+
|
16368 |
+
return ctx.autoFill ?
|
16369 |
+
ctx.autoFill.enabled() :
|
16370 |
+
false;
|
16371 |
+
} );
|
16372 |
+
|
16373 |
+
Api.register( 'autoFill().enable()', function ( flag ) {
|
16374 |
+
return this.iterator( 'table', function ( ctx ) {
|
16375 |
+
if ( ctx.autoFill ) {
|
16376 |
+
ctx.autoFill.enable( flag );
|
16377 |
+
}
|
16378 |
+
} );
|
16379 |
+
} );
|
16380 |
+
|
16381 |
+
Api.register( 'autoFill().disable()', function () {
|
16382 |
+
return this.iterator( 'table', function ( ctx ) {
|
16383 |
+
if ( ctx.autoFill ) {
|
16384 |
+
ctx.autoFill.disable();
|
16385 |
+
}
|
16386 |
+
} );
|
16387 |
+
} );
|
16388 |
+
|
16389 |
+
|
16390 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
16391 |
+
// events so we can automatically initialise
|
16392 |
+
$(document).on( 'preInit.dt.autofill', function (e, settings, json) {
|
16393 |
+
if ( e.namespace !== 'dt' ) {
|
16394 |
+
return;
|
16395 |
+
}
|
16396 |
+
|
16397 |
+
var init = settings.oInit.autoFill;
|
16398 |
+
var defaults = DataTable.defaults.autoFill;
|
16399 |
+
|
16400 |
+
if ( init || defaults ) {
|
16401 |
+
var opts = $.extend( {}, init, defaults );
|
16402 |
+
|
16403 |
+
if ( init !== false ) {
|
16404 |
+
new AutoFill( settings, opts );
|
16405 |
+
}
|
16406 |
+
}
|
16407 |
+
} );
|
16408 |
+
|
16409 |
+
|
16410 |
+
// Alias for access
|
16411 |
+
DataTable.AutoFill = AutoFill;
|
16412 |
+
DataTable.AutoFill = AutoFill;
|
16413 |
+
|
16414 |
+
|
16415 |
+
return AutoFill;
|
16416 |
+
}));
|
16417 |
+
|
16418 |
+
|
16419 |
+
/*! Buttons for DataTables 1.5.1
|
16420 |
+
* ©2016-2017 SpryMedia Ltd - datatables.net/license
|
16421 |
+
*/
|
16422 |
+
|
16423 |
+
(function( factory ){
|
16424 |
+
if ( typeof define === 'function' && define.amd ) {
|
16425 |
+
// AMD
|
16426 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
16427 |
+
return factory( $, window, document );
|
16428 |
+
} );
|
16429 |
+
}
|
16430 |
+
else if ( typeof exports === 'object' ) {
|
16431 |
+
// CommonJS
|
16432 |
+
module.exports = function (root, $) {
|
16433 |
+
if ( ! root ) {
|
16434 |
+
root = window;
|
16435 |
+
}
|
16436 |
+
|
16437 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
16438 |
+
$ = require('datatables.net')(root, $).$;
|
16439 |
+
}
|
16440 |
+
|
16441 |
+
return factory( $, root, root.document );
|
16442 |
+
};
|
16443 |
+
}
|
16444 |
+
else {
|
16445 |
+
// Browser
|
16446 |
+
factory( jQuery, window, document );
|
16447 |
+
}
|
16448 |
+
}(function( $, window, document, undefined ) {
|
16449 |
+
'use strict';
|
16450 |
+
var DataTable = $.fn.dataTable;
|
16451 |
+
|
16452 |
+
|
16453 |
+
// Used for namespacing events added to the document by each instance, so they
|
16454 |
+
// can be removed on destroy
|
16455 |
+
var _instCounter = 0;
|
16456 |
+
|
16457 |
+
// Button namespacing counter for namespacing events on individual buttons
|
16458 |
+
var _buttonCounter = 0;
|
16459 |
+
|
16460 |
+
var _dtButtons = DataTable.ext.buttons;
|
16461 |
+
|
16462 |
+
/**
|
16463 |
+
* [Buttons description]
|
16464 |
+
* @param {[type]}
|
16465 |
+
* @param {[type]}
|
16466 |
+
*/
|
16467 |
+
var Buttons = function( dt, config )
|
16468 |
+
{
|
16469 |
+
// If there is no config set it to an empty object
|
16470 |
+
if ( typeof( config ) === 'undefined' ) {
|
16471 |
+
config = {};
|
16472 |
+
}
|
16473 |
+
|
16474 |
+
// Allow a boolean true for defaults
|
16475 |
+
if ( config === true ) {
|
16476 |
+
config = {};
|
16477 |
+
}
|
16478 |
+
|
16479 |
+
// For easy configuration of buttons an array can be given
|
16480 |
+
if ( $.isArray( config ) ) {
|
16481 |
+
config = { buttons: config };
|
16482 |
+
}
|
16483 |
+
|
16484 |
+
this.c = $.extend( true, {}, Buttons.defaults, config );
|
16485 |
+
|
16486 |
+
// Don't want a deep copy for the buttons
|
16487 |
+
if ( config.buttons ) {
|
16488 |
+
this.c.buttons = config.buttons;
|
16489 |
+
}
|
16490 |
+
|
16491 |
+
this.s = {
|
16492 |
+
dt: new DataTable.Api( dt ),
|
16493 |
+
buttons: [],
|
16494 |
+
listenKeys: '',
|
16495 |
+
namespace: 'dtb'+(_instCounter++)
|
16496 |
+
};
|
16497 |
+
|
16498 |
+
this.dom = {
|
16499 |
+
container: $('<'+this.c.dom.container.tag+'/>')
|
16500 |
+
.addClass( this.c.dom.container.className )
|
16501 |
+
};
|
16502 |
+
|
16503 |
+
this._constructor();
|
16504 |
+
};
|
16505 |
+
|
16506 |
+
|
16507 |
+
$.extend( Buttons.prototype, {
|
16508 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
16509 |
+
* Public methods
|
16510 |
+
*/
|
16511 |
+
|
16512 |
+
/**
|
16513 |
+
* Get the action of a button
|
16514 |
+
* @param {int|string} Button index
|
16515 |
+
* @return {function}
|
16516 |
+
*//**
|
16517 |
+
* Set the action of a button
|
16518 |
+
* @param {node} node Button element
|
16519 |
+
* @param {function} action Function to set
|
16520 |
+
* @return {Buttons} Self for chaining
|
16521 |
+
*/
|
16522 |
+
action: function ( node, action )
|
16523 |
+
{
|
16524 |
+
var button = this._nodeToButton( node );
|
16525 |
+
|
16526 |
+
if ( action === undefined ) {
|
16527 |
+
return button.conf.action;
|
16528 |
+
}
|
16529 |
+
|
16530 |
+
button.conf.action = action;
|
16531 |
+
|
16532 |
+
return this;
|
16533 |
+
},
|
16534 |
+
|
16535 |
+
/**
|
16536 |
+
* Add an active class to the button to make to look active or get current
|
16537 |
+
* active state.
|
16538 |
+
* @param {node} node Button element
|
16539 |
+
* @param {boolean} [flag] Enable / disable flag
|
16540 |
+
* @return {Buttons} Self for chaining or boolean for getter
|
16541 |
+
*/
|
16542 |
+
active: function ( node, flag ) {
|
16543 |
+
var button = this._nodeToButton( node );
|
16544 |
+
var klass = this.c.dom.button.active;
|
16545 |
+
var jqNode = $(button.node);
|
16546 |
+
|
16547 |
+
if ( flag === undefined ) {
|
16548 |
+
return jqNode.hasClass( klass );
|
16549 |
+
}
|
16550 |
+
|
16551 |
+
jqNode.toggleClass( klass, flag === undefined ? true : flag );
|
16552 |
+
|
16553 |
+
return this;
|
16554 |
+
},
|
16555 |
+
|
16556 |
+
/**
|
16557 |
+
* Add a new button
|
16558 |
+
* @param {object} config Button configuration object, base string name or function
|
16559 |
+
* @param {int|string} [idx] Button index for where to insert the button
|
16560 |
+
* @return {Buttons} Self for chaining
|
16561 |
+
*/
|
16562 |
+
add: function ( config, idx )
|
16563 |
+
{
|
16564 |
+
var buttons = this.s.buttons;
|
16565 |
+
|
16566 |
+
if ( typeof idx === 'string' ) {
|
16567 |
+
var split = idx.split('-');
|
16568 |
+
var base = this.s;
|
16569 |
+
|
16570 |
+
for ( var i=0, ien=split.length-1 ; i<ien ; i++ ) {
|
16571 |
+
base = base.buttons[ split[i]*1 ];
|
16572 |
+
}
|
16573 |
+
|
16574 |
+
buttons = base.buttons;
|
16575 |
+
idx = split[ split.length-1 ]*1;
|
16576 |
+
}
|
16577 |
+
|
16578 |
+
this._expandButton( buttons, config, false, idx );
|
16579 |
+
this._draw();
|
16580 |
+
|
16581 |
+
return this;
|
16582 |
+
},
|
16583 |
+
|
16584 |
+
/**
|
16585 |
+
* Get the container node for the buttons
|
16586 |
+
* @return {jQuery} Buttons node
|
16587 |
+
*/
|
16588 |
+
container: function ()
|
16589 |
+
{
|
16590 |
+
return this.dom.container;
|
16591 |
+
},
|
16592 |
+
|
16593 |
+
/**
|
16594 |
+
* Disable a button
|
16595 |
+
* @param {node} node Button node
|
16596 |
+
* @return {Buttons} Self for chaining
|
16597 |
+
*/
|
16598 |
+
disable: function ( node ) {
|
16599 |
+
var button = this._nodeToButton( node );
|
16600 |
+
|
16601 |
+
$(button.node).addClass( this.c.dom.button.disabled );
|
16602 |
+
|
16603 |
+
return this;
|
16604 |
+
},
|
16605 |
+
|
16606 |
+
/**
|
16607 |
+
* Destroy the instance, cleaning up event handlers and removing DOM
|
16608 |
+
* elements
|
16609 |
+
* @return {Buttons} Self for chaining
|
16610 |
+
*/
|
16611 |
+
destroy: function ()
|
16612 |
+
{
|
16613 |
+
// Key event listener
|
16614 |
+
$('body').off( 'keyup.'+this.s.namespace );
|
16615 |
+
|
16616 |
+
// Individual button destroy (so they can remove their own events if
|
16617 |
+
// needed). Take a copy as the array is modified by `remove`
|
16618 |
+
var buttons = this.s.buttons.slice();
|
16619 |
+
var i, ien;
|
16620 |
+
|
16621 |
+
for ( i=0, ien=buttons.length ; i<ien ; i++ ) {
|
16622 |
+
this.remove( buttons[i].node );
|
16623 |
+
}
|
16624 |
+
|
16625 |
+
// Container
|
16626 |
+
this.dom.container.remove();
|
16627 |
+
|
16628 |
+
// Remove from the settings object collection
|
16629 |
+
var buttonInsts = this.s.dt.settings()[0];
|
16630 |
+
|
16631 |
+
for ( i=0, ien=buttonInsts.length ; i<ien ; i++ ) {
|
16632 |
+
if ( buttonInsts.inst === this ) {
|
16633 |
+
buttonInsts.splice( i, 1 );
|
16634 |
+
break;
|
16635 |
+
}
|
16636 |
+
}
|
16637 |
+
|
16638 |
+
return this;
|
16639 |
+
},
|
16640 |
+
|
16641 |
+
/**
|
16642 |
+
* Enable / disable a button
|
16643 |
+
* @param {node} node Button node
|
16644 |
+
* @param {boolean} [flag=true] Enable / disable flag
|
16645 |
+
* @return {Buttons} Self for chaining
|
16646 |
+
*/
|
16647 |
+
enable: function ( node, flag )
|
16648 |
+
{
|
16649 |
+
if ( flag === false ) {
|
16650 |
+
return this.disable( node );
|
16651 |
+
}
|
16652 |
+
|
16653 |
+
var button = this._nodeToButton( node );
|
16654 |
+
$(button.node).removeClass( this.c.dom.button.disabled );
|
16655 |
+
|
16656 |
+
return this;
|
16657 |
+
},
|
16658 |
+
|
16659 |
+
/**
|
16660 |
+
* Get the instance name for the button set selector
|
16661 |
+
* @return {string} Instance name
|
16662 |
+
*/
|
16663 |
+
name: function ()
|
16664 |
+
{
|
16665 |
+
return this.c.name;
|
16666 |
+
},
|
16667 |
+
|
16668 |
+
/**
|
16669 |
+
* Get a button's node
|
16670 |
+
* @param {node} node Button node
|
16671 |
+
* @return {jQuery} Button element
|
16672 |
+
*/
|
16673 |
+
node: function ( node )
|
16674 |
+
{
|
16675 |
+
var button = this._nodeToButton( node );
|
16676 |
+
return $(button.node);
|
16677 |
+
},
|
16678 |
+
|
16679 |
+
/**
|
16680 |
+
* Set / get a processing class on the selected button
|
16681 |
+
* @param {boolean} flag true to add, false to remove, undefined to get
|
16682 |
+
* @return {boolean|Buttons} Getter value or this if a setter.
|
16683 |
+
*/
|
16684 |
+
processing: function ( node, flag )
|
16685 |
+
{
|
16686 |
+
var button = this._nodeToButton( node );
|
16687 |
+
|
16688 |
+
if ( flag === undefined ) {
|
16689 |
+
return $(button.node).hasClass( 'processing' );
|
16690 |
+
}
|
16691 |
+
|
16692 |
+
$(button.node).toggleClass( 'processing', flag );
|
16693 |
+
|
16694 |
+
return this;
|
16695 |
+
},
|
16696 |
+
|
16697 |
+
/**
|
16698 |
+
* Remove a button.
|
16699 |
+
* @param {node} node Button node
|
16700 |
+
* @return {Buttons} Self for chaining
|
16701 |
+
*/
|
16702 |
+
remove: function ( node )
|
16703 |
+
{
|
16704 |
+
var button = this._nodeToButton( node );
|
16705 |
+
var host = this._nodeToHost( node );
|
16706 |
+
var dt = this.s.dt;
|
16707 |
+
|
16708 |
+
// Remove any child buttons first
|
16709 |
+
if ( button.buttons.length ) {
|
16710 |
+
for ( var i=button.buttons.length-1 ; i>=0 ; i-- ) {
|
16711 |
+
this.remove( button.buttons[i].node );
|
16712 |
+
}
|
16713 |
+
}
|
16714 |
+
|
16715 |
+
// Allow the button to remove event handlers, etc
|
16716 |
+
if ( button.conf.destroy ) {
|
16717 |
+
button.conf.destroy.call( dt.button(node), dt, $(node), button.conf );
|
16718 |
+
}
|
16719 |
+
|
16720 |
+
this._removeKey( button.conf );
|
16721 |
+
|
16722 |
+
$(button.node).remove();
|
16723 |
+
|
16724 |
+
var idx = $.inArray( button, host );
|
16725 |
+
host.splice( idx, 1 );
|
16726 |
+
|
16727 |
+
return this;
|
16728 |
+
},
|
16729 |
+
|
16730 |
+
/**
|
16731 |
+
* Get the text for a button
|
16732 |
+
* @param {int|string} node Button index
|
16733 |
+
* @return {string} Button text
|
16734 |
+
*//**
|
16735 |
+
* Set the text for a button
|
16736 |
+
* @param {int|string|function} node Button index
|
16737 |
+
* @param {string} label Text
|
16738 |
+
* @return {Buttons} Self for chaining
|
16739 |
+
*/
|
16740 |
+
text: function ( node, label )
|
16741 |
+
{
|
16742 |
+
var button = this._nodeToButton( node );
|
16743 |
+
var buttonLiner = this.c.dom.collection.buttonLiner;
|
16744 |
+
var linerTag = button.inCollection && buttonLiner && buttonLiner.tag ?
|
16745 |
+
buttonLiner.tag :
|
16746 |
+
this.c.dom.buttonLiner.tag;
|
16747 |
+
var dt = this.s.dt;
|
16748 |
+
var jqNode = $(button.node);
|
16749 |
+
var text = function ( opt ) {
|
16750 |
+
return typeof opt === 'function' ?
|
16751 |
+
opt( dt, jqNode, button.conf ) :
|
16752 |
+
opt;
|
16753 |
+
};
|
16754 |
+
|
16755 |
+
if ( label === undefined ) {
|
16756 |
+
return text( button.conf.text );
|
16757 |
+
}
|
16758 |
+
|
16759 |
+
button.conf.text = label;
|
16760 |
+
|
16761 |
+
if ( linerTag ) {
|
16762 |
+
jqNode.children( linerTag ).html( text(label) );
|
16763 |
+
}
|
16764 |
+
else {
|
16765 |
+
jqNode.html( text(label) );
|
16766 |
+
}
|
16767 |
+
|
16768 |
+
return this;
|
16769 |
+
},
|
16770 |
+
|
16771 |
+
|
16772 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
16773 |
+
* Constructor
|
16774 |
+
*/
|
16775 |
+
|
16776 |
+
/**
|
16777 |
+
* Buttons constructor
|
16778 |
+
* @private
|
16779 |
+
*/
|
16780 |
+
_constructor: function ()
|
16781 |
+
{
|
16782 |
+
var that = this;
|
16783 |
+
var dt = this.s.dt;
|
16784 |
+
var dtSettings = dt.settings()[0];
|
16785 |
+
var buttons = this.c.buttons;
|
16786 |
+
|
16787 |
+
if ( ! dtSettings._buttons ) {
|
16788 |
+
dtSettings._buttons = [];
|
16789 |
+
}
|
16790 |
+
|
16791 |
+
dtSettings._buttons.push( {
|
16792 |
+
inst: this,
|
16793 |
+
name: this.c.name
|
16794 |
+
} );
|
16795 |
+
|
16796 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
16797 |
+
this.add( buttons[i] );
|
16798 |
+
}
|
16799 |
+
|
16800 |
+
dt.on( 'destroy', function () {
|
16801 |
+
that.destroy();
|
16802 |
+
} );
|
16803 |
+
|
16804 |
+
// Global key event binding to listen for button keys
|
16805 |
+
$('body').on( 'keyup.'+this.s.namespace, function ( e ) {
|
16806 |
+
if ( ! document.activeElement || document.activeElement === document.body ) {
|
16807 |
+
// SUse a string of characters for fast lookup of if we need to
|
16808 |
+
// handle this
|
16809 |
+
var character = String.fromCharCode(e.keyCode).toLowerCase();
|
16810 |
+
|
16811 |
+
if ( that.s.listenKeys.toLowerCase().indexOf( character ) !== -1 ) {
|
16812 |
+
that._keypress( character, e );
|
16813 |
+
}
|
16814 |
+
}
|
16815 |
+
} );
|
16816 |
+
},
|
16817 |
+
|
16818 |
+
|
16819 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
16820 |
+
* Private methods
|
16821 |
+
*/
|
16822 |
+
|
16823 |
+
/**
|
16824 |
+
* Add a new button to the key press listener
|
16825 |
+
* @param {object} conf Resolved button configuration object
|
16826 |
+
* @private
|
16827 |
+
*/
|
16828 |
+
_addKey: function ( conf )
|
16829 |
+
{
|
16830 |
+
if ( conf.key ) {
|
16831 |
+
this.s.listenKeys += $.isPlainObject( conf.key ) ?
|
16832 |
+
conf.key.key :
|
16833 |
+
conf.key;
|
16834 |
+
}
|
16835 |
+
},
|
16836 |
+
|
16837 |
+
/**
|
16838 |
+
* Insert the buttons into the container. Call without parameters!
|
16839 |
+
* @param {node} [container] Recursive only - Insert point
|
16840 |
+
* @param {array} [buttons] Recursive only - Buttons array
|
16841 |
+
* @private
|
16842 |
+
*/
|
16843 |
+
_draw: function ( container, buttons )
|
16844 |
+
{
|
16845 |
+
if ( ! container ) {
|
16846 |
+
container = this.dom.container;
|
16847 |
+
buttons = this.s.buttons;
|
16848 |
+
}
|
16849 |
+
|
16850 |
+
container.children().detach();
|
16851 |
+
|
16852 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
16853 |
+
container.append( buttons[i].inserter );
|
16854 |
+
container.append( ' ' );
|
16855 |
+
|
16856 |
+
if ( buttons[i].buttons && buttons[i].buttons.length ) {
|
16857 |
+
this._draw( buttons[i].collection, buttons[i].buttons );
|
16858 |
+
}
|
16859 |
+
}
|
16860 |
+
},
|
16861 |
+
|
16862 |
+
/**
|
16863 |
+
* Create buttons from an array of buttons
|
16864 |
+
* @param {array} attachTo Buttons array to attach to
|
16865 |
+
* @param {object} button Button definition
|
16866 |
+
* @param {boolean} inCollection true if the button is in a collection
|
16867 |
+
* @private
|
16868 |
+
*/
|
16869 |
+
_expandButton: function ( attachTo, button, inCollection, attachPoint )
|
16870 |
+
{
|
16871 |
+
var dt = this.s.dt;
|
16872 |
+
var buttonCounter = 0;
|
16873 |
+
var buttons = ! $.isArray( button ) ?
|
16874 |
+
[ button ] :
|
16875 |
+
button;
|
16876 |
+
|
16877 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
16878 |
+
var conf = this._resolveExtends( buttons[i] );
|
16879 |
+
|
16880 |
+
if ( ! conf ) {
|
16881 |
+
continue;
|
16882 |
+
}
|
16883 |
+
|
16884 |
+
// If the configuration is an array, then expand the buttons at this
|
16885 |
+
// point
|
16886 |
+
if ( $.isArray( conf ) ) {
|
16887 |
+
this._expandButton( attachTo, conf, inCollection, attachPoint );
|
16888 |
+
continue;
|
16889 |
+
}
|
16890 |
+
|
16891 |
+
var built = this._buildButton( conf, inCollection );
|
16892 |
+
if ( ! built ) {
|
16893 |
+
continue;
|
16894 |
+
}
|
16895 |
+
|
16896 |
+
if ( attachPoint !== undefined ) {
|
16897 |
+
attachTo.splice( attachPoint, 0, built );
|
16898 |
+
attachPoint++;
|
16899 |
+
}
|
16900 |
+
else {
|
16901 |
+
attachTo.push( built );
|
16902 |
+
}
|
16903 |
+
|
16904 |
+
if ( built.conf.buttons ) {
|
16905 |
+
var collectionDom = this.c.dom.collection;
|
16906 |
+
built.collection = $('<'+collectionDom.tag+'/>')
|
16907 |
+
.addClass( collectionDom.className )
|
16908 |
+
.attr( 'role', 'menu') ;
|
16909 |
+
built.conf._collection = built.collection;
|
16910 |
+
|
16911 |
+
this._expandButton( built.buttons, built.conf.buttons, true, attachPoint );
|
16912 |
+
}
|
16913 |
+
|
16914 |
+
// init call is made here, rather than buildButton as it needs to
|
16915 |
+
// be selectable, and for that it needs to be in the buttons array
|
16916 |
+
if ( conf.init ) {
|
16917 |
+
conf.init.call( dt.button( built.node ), dt, $(built.node), conf );
|
16918 |
+
}
|
16919 |
+
|
16920 |
+
buttonCounter++;
|
16921 |
+
}
|
16922 |
+
},
|
16923 |
+
|
16924 |
+
/**
|
16925 |
+
* Create an individual button
|
16926 |
+
* @param {object} config Resolved button configuration
|
16927 |
+
* @param {boolean} inCollection `true` if a collection button
|
16928 |
+
* @return {jQuery} Created button node (jQuery)
|
16929 |
+
* @private
|
16930 |
+
*/
|
16931 |
+
_buildButton: function ( config, inCollection )
|
16932 |
+
{
|
16933 |
+
var buttonDom = this.c.dom.button;
|
16934 |
+
var linerDom = this.c.dom.buttonLiner;
|
16935 |
+
var collectionDom = this.c.dom.collection;
|
16936 |
+
var dt = this.s.dt;
|
16937 |
+
var text = function ( opt ) {
|
16938 |
+
return typeof opt === 'function' ?
|
16939 |
+
opt( dt, button, config ) :
|
16940 |
+
opt;
|
16941 |
+
};
|
16942 |
+
|
16943 |
+
if ( inCollection && collectionDom.button ) {
|
16944 |
+
buttonDom = collectionDom.button;
|
16945 |
+
}
|
16946 |
+
|
16947 |
+
if ( inCollection && collectionDom.buttonLiner ) {
|
16948 |
+
linerDom = collectionDom.buttonLiner;
|
16949 |
+
}
|
16950 |
+
|
16951 |
+
// Make sure that the button is available based on whatever requirements
|
16952 |
+
// it has. For example, Flash buttons require Flash
|
16953 |
+
if ( config.available && ! config.available( dt, config ) ) {
|
16954 |
+
return false;
|
16955 |
+
}
|
16956 |
+
|
16957 |
+
var action = function ( e, dt, button, config ) {
|
16958 |
+
config.action.call( dt.button( button ), e, dt, button, config );
|
16959 |
+
|
16960 |
+
$(dt.table().node()).triggerHandler( 'buttons-action.dt', [
|
16961 |
+
dt.button( button ), dt, button, config
|
16962 |
+
] );
|
16963 |
+
};
|
16964 |
+
|
16965 |
+
var button = $('<'+buttonDom.tag+'/>')
|
16966 |
+
.addClass( buttonDom.className )
|
16967 |
+
.attr( 'tabindex', this.s.dt.settings()[0].iTabIndex )
|
16968 |
+
.attr( 'aria-controls', this.s.dt.table().node().id )
|
16969 |
+
.on( 'click.dtb', function (e) {
|
16970 |
+
e.preventDefault();
|
16971 |
+
|
16972 |
+
if ( ! button.hasClass( buttonDom.disabled ) && config.action ) {
|
16973 |
+
action( e, dt, button, config );
|
16974 |
+
}
|
16975 |
+
|
16976 |
+
button.blur();
|
16977 |
+
} )
|
16978 |
+
.on( 'keyup.dtb', function (e) {
|
16979 |
+
if ( e.keyCode === 13 ) {
|
16980 |
+
if ( ! button.hasClass( buttonDom.disabled ) && config.action ) {
|
16981 |
+
action( e, dt, button, config );
|
16982 |
+
}
|
16983 |
+
}
|
16984 |
+
} );
|
16985 |
+
|
16986 |
+
// Make `a` tags act like a link
|
16987 |
+
if ( buttonDom.tag.toLowerCase() === 'a' ) {
|
16988 |
+
button.attr( 'href', '#' );
|
16989 |
+
}
|
16990 |
+
|
16991 |
+
if ( linerDom.tag ) {
|
16992 |
+
var liner = $('<'+linerDom.tag+'/>')
|
16993 |
+
.html( text( config.text ) )
|
16994 |
+
.addClass( linerDom.className );
|
16995 |
+
|
16996 |
+
if ( linerDom.tag.toLowerCase() === 'a' ) {
|
16997 |
+
liner.attr( 'href', '#' );
|
16998 |
+
}
|
16999 |
+
|
17000 |
+
button.append( liner );
|
17001 |
+
}
|
17002 |
+
else {
|
17003 |
+
button.html( text( config.text ) );
|
17004 |
+
}
|
17005 |
+
|
17006 |
+
if ( config.enabled === false ) {
|
17007 |
+
button.addClass( buttonDom.disabled );
|
17008 |
+
}
|
17009 |
+
|
17010 |
+
if ( config.className ) {
|
17011 |
+
button.addClass( config.className );
|
17012 |
+
}
|
17013 |
+
|
17014 |
+
if ( config.titleAttr ) {
|
17015 |
+
button.attr( 'title', text( config.titleAttr ) );
|
17016 |
+
}
|
17017 |
+
|
17018 |
+
if ( config.attr ) {
|
17019 |
+
button.attr( config.attr );
|
17020 |
+
}
|
17021 |
+
|
17022 |
+
if ( ! config.namespace ) {
|
17023 |
+
config.namespace = '.dt-button-'+(_buttonCounter++);
|
17024 |
+
}
|
17025 |
+
|
17026 |
+
var buttonContainer = this.c.dom.buttonContainer;
|
17027 |
+
var inserter;
|
17028 |
+
if ( buttonContainer && buttonContainer.tag ) {
|
17029 |
+
inserter = $('<'+buttonContainer.tag+'/>')
|
17030 |
+
.addClass( buttonContainer.className )
|
17031 |
+
.append( button );
|
17032 |
+
}
|
17033 |
+
else {
|
17034 |
+
inserter = button;
|
17035 |
+
}
|
17036 |
+
|
17037 |
+
this._addKey( config );
|
17038 |
+
|
17039 |
+
return {
|
17040 |
+
conf: config,
|
17041 |
+
node: button.get(0),
|
17042 |
+
inserter: inserter,
|
17043 |
+
buttons: [],
|
17044 |
+
inCollection: inCollection,
|
17045 |
+
collection: null
|
17046 |
+
};
|
17047 |
+
},
|
17048 |
+
|
17049 |
+
/**
|
17050 |
+
* Get the button object from a node (recursive)
|
17051 |
+
* @param {node} node Button node
|
17052 |
+
* @param {array} [buttons] Button array, uses base if not defined
|
17053 |
+
* @return {object} Button object
|
17054 |
+
* @private
|
17055 |
+
*/
|
17056 |
+
_nodeToButton: function ( node, buttons )
|
17057 |
+
{
|
17058 |
+
if ( ! buttons ) {
|
17059 |
+
buttons = this.s.buttons;
|
17060 |
+
}
|
17061 |
+
|
17062 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
17063 |
+
if ( buttons[i].node === node ) {
|
17064 |
+
return buttons[i];
|
17065 |
+
}
|
17066 |
+
|
17067 |
+
if ( buttons[i].buttons.length ) {
|
17068 |
+
var ret = this._nodeToButton( node, buttons[i].buttons );
|
17069 |
+
|
17070 |
+
if ( ret ) {
|
17071 |
+
return ret;
|
17072 |
+
}
|
17073 |
+
}
|
17074 |
+
}
|
17075 |
+
},
|
17076 |
+
|
17077 |
+
/**
|
17078 |
+
* Get container array for a button from a button node (recursive)
|
17079 |
+
* @param {node} node Button node
|
17080 |
+
* @param {array} [buttons] Button array, uses base if not defined
|
17081 |
+
* @return {array} Button's host array
|
17082 |
+
* @private
|
17083 |
+
*/
|
17084 |
+
_nodeToHost: function ( node, buttons )
|
17085 |
+
{
|
17086 |
+
if ( ! buttons ) {
|
17087 |
+
buttons = this.s.buttons;
|
17088 |
+
}
|
17089 |
+
|
17090 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
17091 |
+
if ( buttons[i].node === node ) {
|
17092 |
+
return buttons;
|
17093 |
+
}
|
17094 |
+
|
17095 |
+
if ( buttons[i].buttons.length ) {
|
17096 |
+
var ret = this._nodeToHost( node, buttons[i].buttons );
|
17097 |
+
|
17098 |
+
if ( ret ) {
|
17099 |
+
return ret;
|
17100 |
+
}
|
17101 |
+
}
|
17102 |
+
}
|
17103 |
+
},
|
17104 |
+
|
17105 |
+
/**
|
17106 |
+
* Handle a key press - determine if any button's key configured matches
|
17107 |
+
* what was typed and trigger the action if so.
|
17108 |
+
* @param {string} character The character pressed
|
17109 |
+
* @param {object} e Key event that triggered this call
|
17110 |
+
* @private
|
17111 |
+
*/
|
17112 |
+
_keypress: function ( character, e )
|
17113 |
+
{
|
17114 |
+
// Check if this button press already activated on another instance of Buttons
|
17115 |
+
if ( e._buttonsHandled ) {
|
17116 |
+
return;
|
17117 |
+
}
|
17118 |
+
|
17119 |
+
var run = function ( conf, node ) {
|
17120 |
+
if ( ! conf.key ) {
|
17121 |
+
return;
|
17122 |
+
}
|
17123 |
+
|
17124 |
+
if ( conf.key === character ) {
|
17125 |
+
e._buttonsHandled = true;
|
17126 |
+
$(node).click();
|
17127 |
+
}
|
17128 |
+
else if ( $.isPlainObject( conf.key ) ) {
|
17129 |
+
if ( conf.key.key !== character ) {
|
17130 |
+
return;
|
17131 |
+
}
|
17132 |
+
|
17133 |
+
if ( conf.key.shiftKey && ! e.shiftKey ) {
|
17134 |
+
return;
|
17135 |
+
}
|
17136 |
+
|
17137 |
+
if ( conf.key.altKey && ! e.altKey ) {
|
17138 |
+
return;
|
17139 |
+
}
|
17140 |
+
|
17141 |
+
if ( conf.key.ctrlKey && ! e.ctrlKey ) {
|
17142 |
+
return;
|
17143 |
+
}
|
17144 |
+
|
17145 |
+
if ( conf.key.metaKey && ! e.metaKey ) {
|
17146 |
+
return;
|
17147 |
+
}
|
17148 |
+
|
17149 |
+
// Made it this far - it is good
|
17150 |
+
e._buttonsHandled = true;
|
17151 |
+
$(node).click();
|
17152 |
+
}
|
17153 |
+
};
|
17154 |
+
|
17155 |
+
var recurse = function ( a ) {
|
17156 |
+
for ( var i=0, ien=a.length ; i<ien ; i++ ) {
|
17157 |
+
run( a[i].conf, a[i].node );
|
17158 |
+
|
17159 |
+
if ( a[i].buttons.length ) {
|
17160 |
+
recurse( a[i].buttons );
|
17161 |
+
}
|
17162 |
+
}
|
17163 |
+
};
|
17164 |
+
|
17165 |
+
recurse( this.s.buttons );
|
17166 |
+
},
|
17167 |
+
|
17168 |
+
/**
|
17169 |
+
* Remove a key from the key listener for this instance (to be used when a
|
17170 |
+
* button is removed)
|
17171 |
+
* @param {object} conf Button configuration
|
17172 |
+
* @private
|
17173 |
+
*/
|
17174 |
+
_removeKey: function ( conf )
|
17175 |
+
{
|
17176 |
+
if ( conf.key ) {
|
17177 |
+
var character = $.isPlainObject( conf.key ) ?
|
17178 |
+
conf.key.key :
|
17179 |
+
conf.key;
|
17180 |
+
|
17181 |
+
// Remove only one character, as multiple buttons could have the
|
17182 |
+
// same listening key
|
17183 |
+
var a = this.s.listenKeys.split('');
|
17184 |
+
var idx = $.inArray( character, a );
|
17185 |
+
a.splice( idx, 1 );
|
17186 |
+
this.s.listenKeys = a.join('');
|
17187 |
+
}
|
17188 |
+
},
|
17189 |
+
|
17190 |
+
/**
|
17191 |
+
* Resolve a button configuration
|
17192 |
+
* @param {string|function|object} conf Button config to resolve
|
17193 |
+
* @return {object} Button configuration
|
17194 |
+
* @private
|
17195 |
+
*/
|
17196 |
+
_resolveExtends: function ( conf )
|
17197 |
+
{
|
17198 |
+
var dt = this.s.dt;
|
17199 |
+
var i, ien;
|
17200 |
+
var toConfObject = function ( base ) {
|
17201 |
+
var loop = 0;
|
17202 |
+
|
17203 |
+
// Loop until we have resolved to a button configuration, or an
|
17204 |
+
// array of button configurations (which will be iterated
|
17205 |
+
// separately)
|
17206 |
+
while ( ! $.isPlainObject(base) && ! $.isArray(base) ) {
|
17207 |
+
if ( base === undefined ) {
|
17208 |
+
return;
|
17209 |
+
}
|
17210 |
+
|
17211 |
+
if ( typeof base === 'function' ) {
|
17212 |
+
base = base( dt, conf );
|
17213 |
+
|
17214 |
+
if ( ! base ) {
|
17215 |
+
return false;
|
17216 |
+
}
|
17217 |
+
}
|
17218 |
+
else if ( typeof base === 'string' ) {
|
17219 |
+
if ( ! _dtButtons[ base ] ) {
|
17220 |
+
throw 'Unknown button type: '+base;
|
17221 |
+
}
|
17222 |
+
|
17223 |
+
base = _dtButtons[ base ];
|
17224 |
+
}
|
17225 |
+
|
17226 |
+
loop++;
|
17227 |
+
if ( loop > 30 ) {
|
17228 |
+
// Protect against misconfiguration killing the browser
|
17229 |
+
throw 'Buttons: Too many iterations';
|
17230 |
+
}
|
17231 |
+
}
|
17232 |
+
|
17233 |
+
return $.isArray( base ) ?
|
17234 |
+
base :
|
17235 |
+
$.extend( {}, base );
|
17236 |
+
};
|
17237 |
+
|
17238 |
+
conf = toConfObject( conf );
|
17239 |
+
|
17240 |
+
while ( conf && conf.extend ) {
|
17241 |
+
// Use `toConfObject` in case the button definition being extended
|
17242 |
+
// is itself a string or a function
|
17243 |
+
if ( ! _dtButtons[ conf.extend ] ) {
|
17244 |
+
throw 'Cannot extend unknown button type: '+conf.extend;
|
17245 |
+
}
|
17246 |
+
|
17247 |
+
var objArray = toConfObject( _dtButtons[ conf.extend ] );
|
17248 |
+
if ( $.isArray( objArray ) ) {
|
17249 |
+
return objArray;
|
17250 |
+
}
|
17251 |
+
else if ( ! objArray ) {
|
17252 |
+
// This is a little brutal as it might be possible to have a
|
17253 |
+
// valid button without the extend, but if there is no extend
|
17254 |
+
// then the host button would be acting in an undefined state
|
17255 |
+
return false;
|
17256 |
+
}
|
17257 |
+
|
17258 |
+
// Stash the current class name
|
17259 |
+
var originalClassName = objArray.className;
|
17260 |
+
|
17261 |
+
conf = $.extend( {}, objArray, conf );
|
17262 |
+
|
17263 |
+
// The extend will have overwritten the original class name if the
|
17264 |
+
// `conf` object also assigned a class, but we want to concatenate
|
17265 |
+
// them so they are list that is combined from all extended buttons
|
17266 |
+
if ( originalClassName && conf.className !== originalClassName ) {
|
17267 |
+
conf.className = originalClassName+' '+conf.className;
|
17268 |
+
}
|
17269 |
+
|
17270 |
+
// Buttons to be added to a collection -gives the ability to define
|
17271 |
+
// if buttons should be added to the start or end of a collection
|
17272 |
+
var postfixButtons = conf.postfixButtons;
|
17273 |
+
if ( postfixButtons ) {
|
17274 |
+
if ( ! conf.buttons ) {
|
17275 |
+
conf.buttons = [];
|
17276 |
+
}
|
17277 |
+
|
17278 |
+
for ( i=0, ien=postfixButtons.length ; i<ien ; i++ ) {
|
17279 |
+
conf.buttons.push( postfixButtons[i] );
|
17280 |
+
}
|
17281 |
+
|
17282 |
+
conf.postfixButtons = null;
|
17283 |
+
}
|
17284 |
+
|
17285 |
+
var prefixButtons = conf.prefixButtons;
|
17286 |
+
if ( prefixButtons ) {
|
17287 |
+
if ( ! conf.buttons ) {
|
17288 |
+
conf.buttons = [];
|
17289 |
+
}
|
17290 |
+
|
17291 |
+
for ( i=0, ien=prefixButtons.length ; i<ien ; i++ ) {
|
17292 |
+
conf.buttons.splice( i, 0, prefixButtons[i] );
|
17293 |
+
}
|
17294 |
+
|
17295 |
+
conf.prefixButtons = null;
|
17296 |
+
}
|
17297 |
+
|
17298 |
+
// Although we want the `conf` object to overwrite almost all of
|
17299 |
+
// the properties of the object being extended, the `extend`
|
17300 |
+
// property should come from the object being extended
|
17301 |
+
conf.extend = objArray.extend;
|
17302 |
+
}
|
17303 |
+
|
17304 |
+
return conf;
|
17305 |
+
}
|
17306 |
+
} );
|
17307 |
+
|
17308 |
+
|
17309 |
+
|
17310 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
17311 |
+
* Statics
|
17312 |
+
*/
|
17313 |
+
|
17314 |
+
/**
|
17315 |
+
* Show / hide a background layer behind a collection
|
17316 |
+
* @param {boolean} Flag to indicate if the background should be shown or
|
17317 |
+
* hidden
|
17318 |
+
* @param {string} Class to assign to the background
|
17319 |
+
* @static
|
17320 |
+
*/
|
17321 |
+
Buttons.background = function ( show, className, fade ) {
|
17322 |
+
if ( fade === undefined ) {
|
17323 |
+
fade = 400;
|
17324 |
+
}
|
17325 |
+
|
17326 |
+
if ( show ) {
|
17327 |
+
$('<div/>')
|
17328 |
+
.addClass( className )
|
17329 |
+
.css( 'display', 'none' )
|
17330 |
+
.appendTo( 'body' )
|
17331 |
+
.fadeIn( fade );
|
17332 |
+
}
|
17333 |
+
else {
|
17334 |
+
$('body > div.'+className)
|
17335 |
+
.fadeOut( fade, function () {
|
17336 |
+
$(this)
|
17337 |
+
.removeClass( className )
|
17338 |
+
.remove();
|
17339 |
+
} );
|
17340 |
+
}
|
17341 |
+
};
|
17342 |
+
|
17343 |
+
/**
|
17344 |
+
* Instance selector - select Buttons instances based on an instance selector
|
17345 |
+
* value from the buttons assigned to a DataTable. This is only useful if
|
17346 |
+
* multiple instances are attached to a DataTable.
|
17347 |
+
* @param {string|int|array} Instance selector - see `instance-selector`
|
17348 |
+
* documentation on the DataTables site
|
17349 |
+
* @param {array} Button instance array that was attached to the DataTables
|
17350 |
+
* settings object
|
17351 |
+
* @return {array} Buttons instances
|
17352 |
+
* @static
|
17353 |
+
*/
|
17354 |
+
Buttons.instanceSelector = function ( group, buttons )
|
17355 |
+
{
|
17356 |
+
if ( ! group ) {
|
17357 |
+
return $.map( buttons, function ( v ) {
|
17358 |
+
return v.inst;
|
17359 |
+
} );
|
17360 |
+
}
|
17361 |
+
|
17362 |
+
var ret = [];
|
17363 |
+
var names = $.map( buttons, function ( v ) {
|
17364 |
+
return v.name;
|
17365 |
+
} );
|
17366 |
+
|
17367 |
+
// Flatten the group selector into an array of single options
|
17368 |
+
var process = function ( input ) {
|
17369 |
+
if ( $.isArray( input ) ) {
|
17370 |
+
for ( var i=0, ien=input.length ; i<ien ; i++ ) {
|
17371 |
+
process( input[i] );
|
17372 |
+
}
|
17373 |
+
return;
|
17374 |
+
}
|
17375 |
+
|
17376 |
+
if ( typeof input === 'string' ) {
|
17377 |
+
if ( input.indexOf( ',' ) !== -1 ) {
|
17378 |
+
// String selector, list of names
|
17379 |
+
process( input.split(',') );
|
17380 |
+
}
|
17381 |
+
else {
|
17382 |
+
// String selector individual name
|
17383 |
+
var idx = $.inArray( $.trim(input), names );
|
17384 |
+
|
17385 |
+
if ( idx !== -1 ) {
|
17386 |
+
ret.push( buttons[ idx ].inst );
|
17387 |
+
}
|
17388 |
+
}
|
17389 |
+
}
|
17390 |
+
else if ( typeof input === 'number' ) {
|
17391 |
+
// Index selector
|
17392 |
+
ret.push( buttons[ input ].inst );
|
17393 |
+
}
|
17394 |
+
};
|
17395 |
+
|
17396 |
+
process( group );
|
17397 |
+
|
17398 |
+
return ret;
|
17399 |
+
};
|
17400 |
+
|
17401 |
+
/**
|
17402 |
+
* Button selector - select one or more buttons from a selector input so some
|
17403 |
+
* operation can be performed on them.
|
17404 |
+
* @param {array} Button instances array that the selector should operate on
|
17405 |
+
* @param {string|int|node|jQuery|array} Button selector - see
|
17406 |
+
* `button-selector` documentation on the DataTables site
|
17407 |
+
* @return {array} Array of objects containing `inst` and `idx` properties of
|
17408 |
+
* the selected buttons so you know which instance each button belongs to.
|
17409 |
+
* @static
|
17410 |
+
*/
|
17411 |
+
Buttons.buttonSelector = function ( insts, selector )
|
17412 |
+
{
|
17413 |
+
var ret = [];
|
17414 |
+
var nodeBuilder = function ( a, buttons, baseIdx ) {
|
17415 |
+
var button;
|
17416 |
+
var idx;
|
17417 |
+
|
17418 |
+
for ( var i=0, ien=buttons.length ; i<ien ; i++ ) {
|
17419 |
+
button = buttons[i];
|
17420 |
+
|
17421 |
+
if ( button ) {
|
17422 |
+
idx = baseIdx !== undefined ?
|
17423 |
+
baseIdx+i :
|
17424 |
+
i+'';
|
17425 |
+
|
17426 |
+
a.push( {
|
17427 |
+
node: button.node,
|
17428 |
+
name: button.conf.name,
|
17429 |
+
idx: idx
|
17430 |
+
} );
|
17431 |
+
|
17432 |
+
if ( button.buttons ) {
|
17433 |
+
nodeBuilder( a, button.buttons, idx+'-' );
|
17434 |
+
}
|
17435 |
+
}
|
17436 |
+
}
|
17437 |
+
};
|
17438 |
+
|
17439 |
+
var run = function ( selector, inst ) {
|
17440 |
+
var i, ien;
|
17441 |
+
var buttons = [];
|
17442 |
+
nodeBuilder( buttons, inst.s.buttons );
|
17443 |
+
|
17444 |
+
var nodes = $.map( buttons, function (v) {
|
17445 |
+
return v.node;
|
17446 |
+
} );
|
17447 |
+
|
17448 |
+
if ( $.isArray( selector ) || selector instanceof $ ) {
|
17449 |
+
for ( i=0, ien=selector.length ; i<ien ; i++ ) {
|
17450 |
+
run( selector[i], inst );
|
17451 |
+
}
|
17452 |
+
return;
|
17453 |
+
}
|
17454 |
+
|
17455 |
+
if ( selector === null || selector === undefined || selector === '*' ) {
|
17456 |
+
// Select all
|
17457 |
+
for ( i=0, ien=buttons.length ; i<ien ; i++ ) {
|
17458 |
+
ret.push( {
|
17459 |
+
inst: inst,
|
17460 |
+
node: buttons[i].node
|
17461 |
+
} );
|
17462 |
+
}
|
17463 |
+
}
|
17464 |
+
else if ( typeof selector === 'number' ) {
|
17465 |
+
// Main button index selector
|
17466 |
+
ret.push( {
|
17467 |
+
inst: inst,
|
17468 |
+
node: inst.s.buttons[ selector ].node
|
17469 |
+
} );
|
17470 |
+
}
|
17471 |
+
else if ( typeof selector === 'string' ) {
|
17472 |
+
if ( selector.indexOf( ',' ) !== -1 ) {
|
17473 |
+
// Split
|
17474 |
+
var a = selector.split(',');
|
17475 |
+
|
17476 |
+
for ( i=0, ien=a.length ; i<ien ; i++ ) {
|
17477 |
+
run( $.trim(a[i]), inst );
|
17478 |
+
}
|
17479 |
+
}
|
17480 |
+
else if ( selector.match( /^\d+(\-\d+)*$/ ) ) {
|
17481 |
+
// Sub-button index selector
|
17482 |
+
var indexes = $.map( buttons, function (v) {
|
17483 |
+
return v.idx;
|
17484 |
+
} );
|
17485 |
+
|
17486 |
+
ret.push( {
|
17487 |
+
inst: inst,
|
17488 |
+
node: buttons[ $.inArray( selector, indexes ) ].node
|
17489 |
+
} );
|
17490 |
+
}
|
17491 |
+
else if ( selector.indexOf( ':name' ) !== -1 ) {
|
17492 |
+
// Button name selector
|
17493 |
+
var name = selector.replace( ':name', '' );
|
17494 |
+
|
17495 |
+
for ( i=0, ien=buttons.length ; i<ien ; i++ ) {
|
17496 |
+
if ( buttons[i].name === name ) {
|
17497 |
+
ret.push( {
|
17498 |
+
inst: inst,
|
17499 |
+
node: buttons[i].node
|
17500 |
+
} );
|
17501 |
+
}
|
17502 |
+
}
|
17503 |
+
}
|
17504 |
+
else {
|
17505 |
+
// jQuery selector on the nodes
|
17506 |
+
$( nodes ).filter( selector ).each( function () {
|
17507 |
+
ret.push( {
|
17508 |
+
inst: inst,
|
17509 |
+
node: this
|
17510 |
+
} );
|
17511 |
+
} );
|
17512 |
+
}
|
17513 |
+
}
|
17514 |
+
else if ( typeof selector === 'object' && selector.nodeName ) {
|
17515 |
+
// Node selector
|
17516 |
+
var idx = $.inArray( selector, nodes );
|
17517 |
+
|
17518 |
+
if ( idx !== -1 ) {
|
17519 |
+
ret.push( {
|
17520 |
+
inst: inst,
|
17521 |
+
node: nodes[ idx ]
|
17522 |
+
} );
|
17523 |
+
}
|
17524 |
+
}
|
17525 |
+
};
|
17526 |
+
|
17527 |
+
|
17528 |
+
for ( var i=0, ien=insts.length ; i<ien ; i++ ) {
|
17529 |
+
var inst = insts[i];
|
17530 |
+
|
17531 |
+
run( selector, inst );
|
17532 |
+
}
|
17533 |
+
|
17534 |
+
return ret;
|
17535 |
+
};
|
17536 |
+
|
17537 |
+
|
17538 |
+
/**
|
17539 |
+
* Buttons defaults. For full documentation, please refer to the docs/option
|
17540 |
+
* directory or the DataTables site.
|
17541 |
+
* @type {Object}
|
17542 |
+
* @static
|
17543 |
+
*/
|
17544 |
+
Buttons.defaults = {
|
17545 |
+
buttons: [ 'copy', 'excel', 'csv', 'pdf', 'print' ],
|
17546 |
+
name: 'main',
|
17547 |
+
tabIndex: 0,
|
17548 |
+
dom: {
|
17549 |
+
container: {
|
17550 |
+
tag: 'div',
|
17551 |
+
className: 'dt-buttons'
|
17552 |
+
},
|
17553 |
+
collection: {
|
17554 |
+
tag: 'div',
|
17555 |
+
className: 'dt-button-collection'
|
17556 |
+
},
|
17557 |
+
button: {
|
17558 |
+
tag: 'button',
|
17559 |
+
className: 'dt-button',
|
17560 |
+
active: 'active',
|
17561 |
+
disabled: 'disabled'
|
17562 |
+
},
|
17563 |
+
buttonLiner: {
|
17564 |
+
tag: 'span',
|
17565 |
+
className: ''
|
17566 |
+
}
|
17567 |
+
}
|
17568 |
+
};
|
17569 |
+
|
17570 |
+
/**
|
17571 |
+
* Version information
|
17572 |
+
* @type {string}
|
17573 |
+
* @static
|
17574 |
+
*/
|
17575 |
+
Buttons.version = '1.5.1';
|
17576 |
+
|
17577 |
+
|
17578 |
+
$.extend( _dtButtons, {
|
17579 |
+
collection: {
|
17580 |
+
text: function ( dt ) {
|
17581 |
+
return dt.i18n( 'buttons.collection', 'Collection' );
|
17582 |
+
},
|
17583 |
+
className: 'buttons-collection',
|
17584 |
+
action: function ( e, dt, button, config ) {
|
17585 |
+
var host = button;
|
17586 |
+
var collectionParent = $(button).parents('div.dt-button-collection');
|
17587 |
+
var hostPosition = host.position();
|
17588 |
+
var tableContainer = $( dt.table().container() );
|
17589 |
+
var multiLevel = false;
|
17590 |
+
var insertPoint = host;
|
17591 |
+
|
17592 |
+
// Remove any old collection
|
17593 |
+
if ( collectionParent.length ) {
|
17594 |
+
multiLevel = $('.dt-button-collection').position();
|
17595 |
+
insertPoint = collectionParent;
|
17596 |
+
$('body').trigger( 'click.dtb-collection' );
|
17597 |
+
}
|
17598 |
+
|
17599 |
+
config._collection
|
17600 |
+
.addClass( config.collectionLayout )
|
17601 |
+
.css( 'display', 'none' )
|
17602 |
+
.insertAfter( insertPoint )
|
17603 |
+
.fadeIn( config.fade );
|
17604 |
+
|
17605 |
+
|
17606 |
+
var position = config._collection.css( 'position' );
|
17607 |
+
|
17608 |
+
if ( multiLevel && position === 'absolute' ) {
|
17609 |
+
config._collection.css( {
|
17610 |
+
top: multiLevel.top,
|
17611 |
+
left: multiLevel.left
|
17612 |
+
} );
|
17613 |
+
}
|
17614 |
+
else if ( position === 'absolute' ) {
|
17615 |
+
config._collection.css( {
|
17616 |
+
top: hostPosition.top + host.outerHeight(),
|
17617 |
+
left: hostPosition.left
|
17618 |
+
} );
|
17619 |
+
|
17620 |
+
// calculate overflow when positioned beneath
|
17621 |
+
var tableBottom = tableContainer.offset().top + tableContainer.height();
|
17622 |
+
var listBottom = hostPosition.top + host.outerHeight() + config._collection.outerHeight();
|
17623 |
+
var bottomOverflow = listBottom - tableBottom;
|
17624 |
+
|
17625 |
+
// calculate overflow when positioned above
|
17626 |
+
var listTop = hostPosition.top - config._collection.outerHeight();
|
17627 |
+
var tableTop = tableContainer.offset().top;
|
17628 |
+
var topOverflow = tableTop - listTop;
|
17629 |
+
|
17630 |
+
// if bottom overflow is larger, move to the top because it fits better
|
17631 |
+
if (bottomOverflow > topOverflow) {
|
17632 |
+
config._collection.css( 'top', hostPosition.top - config._collection.outerHeight() - 5);
|
17633 |
+
}
|
17634 |
+
|
17635 |
+
var listRight = hostPosition.left + config._collection.outerWidth();
|
17636 |
+
var tableRight = tableContainer.offset().left + tableContainer.width();
|
17637 |
+
if ( listRight > tableRight ) {
|
17638 |
+
config._collection.css( 'left', hostPosition.left - ( listRight - tableRight ) );
|
17639 |
+
}
|
17640 |
+
}
|
17641 |
+
else {
|
17642 |
+
// Fix position - centre on screen
|
17643 |
+
var top = config._collection.height() / 2;
|
17644 |
+
if ( top > $(window).height() / 2 ) {
|
17645 |
+
top = $(window).height() / 2;
|
17646 |
+
}
|
17647 |
+
|
17648 |
+
config._collection.css( 'marginTop', top*-1 );
|
17649 |
+
}
|
17650 |
+
|
17651 |
+
if ( config.background ) {
|
17652 |
+
Buttons.background( true, config.backgroundClassName, config.fade );
|
17653 |
+
}
|
17654 |
+
|
17655 |
+
// Need to break the 'thread' for the collection button being
|
17656 |
+
// activated by a click - it would also trigger this event
|
17657 |
+
setTimeout( function () {
|
17658 |
+
// This is bonkers, but if we don't have a click listener on the
|
17659 |
+
// background element, iOS Safari will ignore the body click
|
17660 |
+
// listener below. An empty function here is all that is
|
17661 |
+
// required to make it work...
|
17662 |
+
$('div.dt-button-background').on( 'click.dtb-collection', function () {} );
|
17663 |
+
|
17664 |
+
$('body').on( 'click.dtb-collection', function (e) {
|
17665 |
+
// andSelf is deprecated in jQ1.8, but we want 1.7 compat
|
17666 |
+
var back = $.fn.addBack ? 'addBack' : 'andSelf';
|
17667 |
+
|
17668 |
+
if ( ! $(e.target).parents()[back]().filter( config._collection ).length ) {
|
17669 |
+
config._collection
|
17670 |
+
.fadeOut( config.fade, function () {
|
17671 |
+
config._collection.detach();
|
17672 |
+
} );
|
17673 |
+
|
17674 |
+
$('div.dt-button-background').off( 'click.dtb-collection' );
|
17675 |
+
Buttons.background( false, config.backgroundClassName, config.fade );
|
17676 |
+
|
17677 |
+
$('body').off( 'click.dtb-collection' );
|
17678 |
+
dt.off( 'buttons-action.b-internal' );
|
17679 |
+
}
|
17680 |
+
} );
|
17681 |
+
}, 10 );
|
17682 |
+
|
17683 |
+
if ( config.autoClose ) {
|
17684 |
+
dt.on( 'buttons-action.b-internal', function () {
|
17685 |
+
$('div.dt-button-background').click();
|
17686 |
+
} );
|
17687 |
+
}
|
17688 |
+
},
|
17689 |
+
background: true,
|
17690 |
+
collectionLayout: '',
|
17691 |
+
backgroundClassName: 'dt-button-background',
|
17692 |
+
autoClose: false,
|
17693 |
+
fade: 400,
|
17694 |
+
attr: {
|
17695 |
+
'aria-haspopup': true
|
17696 |
+
}
|
17697 |
+
},
|
17698 |
+
copy: function ( dt, conf ) {
|
17699 |
+
if ( _dtButtons.copyHtml5 ) {
|
17700 |
+
return 'copyHtml5';
|
17701 |
+
}
|
17702 |
+
if ( _dtButtons.copyFlash && _dtButtons.copyFlash.available( dt, conf ) ) {
|
17703 |
+
return 'copyFlash';
|
17704 |
+
}
|
17705 |
+
},
|
17706 |
+
csv: function ( dt, conf ) {
|
17707 |
+
// Common option that will use the HTML5 or Flash export buttons
|
17708 |
+
if ( _dtButtons.csvHtml5 && _dtButtons.csvHtml5.available( dt, conf ) ) {
|
17709 |
+
return 'csvHtml5';
|
17710 |
+
}
|
17711 |
+
if ( _dtButtons.csvFlash && _dtButtons.csvFlash.available( dt, conf ) ) {
|
17712 |
+
return 'csvFlash';
|
17713 |
+
}
|
17714 |
+
},
|
17715 |
+
excel: function ( dt, conf ) {
|
17716 |
+
// Common option that will use the HTML5 or Flash export buttons
|
17717 |
+
if ( _dtButtons.excelHtml5 && _dtButtons.excelHtml5.available( dt, conf ) ) {
|
17718 |
+
return 'excelHtml5';
|
17719 |
+
}
|
17720 |
+
if ( _dtButtons.excelFlash && _dtButtons.excelFlash.available( dt, conf ) ) {
|
17721 |
+
return 'excelFlash';
|
17722 |
+
}
|
17723 |
+
},
|
17724 |
+
pdf: function ( dt, conf ) {
|
17725 |
+
// Common option that will use the HTML5 or Flash export buttons
|
17726 |
+
if ( _dtButtons.pdfHtml5 && _dtButtons.pdfHtml5.available( dt, conf ) ) {
|
17727 |
+
return 'pdfHtml5';
|
17728 |
+
}
|
17729 |
+
if ( _dtButtons.pdfFlash && _dtButtons.pdfFlash.available( dt, conf ) ) {
|
17730 |
+
return 'pdfFlash';
|
17731 |
+
}
|
17732 |
+
},
|
17733 |
+
pageLength: function ( dt ) {
|
17734 |
+
var lengthMenu = dt.settings()[0].aLengthMenu;
|
17735 |
+
var vals = $.isArray( lengthMenu[0] ) ? lengthMenu[0] : lengthMenu;
|
17736 |
+
var lang = $.isArray( lengthMenu[0] ) ? lengthMenu[1] : lengthMenu;
|
17737 |
+
var text = function ( dt ) {
|
17738 |
+
return dt.i18n( 'buttons.pageLength', {
|
17739 |
+
"-1": 'Show all rows',
|
17740 |
+
_: 'Show %d rows'
|
17741 |
+
}, dt.page.len() );
|
17742 |
+
};
|
17743 |
+
|
17744 |
+
return {
|
17745 |
+
extend: 'collection',
|
17746 |
+
text: text,
|
17747 |
+
className: 'buttons-page-length',
|
17748 |
+
autoClose: true,
|
17749 |
+
buttons: $.map( vals, function ( val, i ) {
|
17750 |
+
return {
|
17751 |
+
text: lang[i],
|
17752 |
+
className: 'button-page-length',
|
17753 |
+
action: function ( e, dt ) {
|
17754 |
+
dt.page.len( val ).draw();
|
17755 |
+
},
|
17756 |
+
init: function ( dt, node, conf ) {
|
17757 |
+
var that = this;
|
17758 |
+
var fn = function () {
|
17759 |
+
that.active( dt.page.len() === val );
|
17760 |
+
};
|
17761 |
+
|
17762 |
+
dt.on( 'length.dt'+conf.namespace, fn );
|
17763 |
+
fn();
|
17764 |
+
},
|
17765 |
+
destroy: function ( dt, node, conf ) {
|
17766 |
+
dt.off( 'length.dt'+conf.namespace );
|
17767 |
+
}
|
17768 |
+
};
|
17769 |
+
} ),
|
17770 |
+
init: function ( dt, node, conf ) {
|
17771 |
+
var that = this;
|
17772 |
+
dt.on( 'length.dt'+conf.namespace, function () {
|
17773 |
+
that.text( text( dt ) );
|
17774 |
+
} );
|
17775 |
+
},
|
17776 |
+
destroy: function ( dt, node, conf ) {
|
17777 |
+
dt.off( 'length.dt'+conf.namespace );
|
17778 |
+
}
|
17779 |
+
};
|
17780 |
+
}
|
17781 |
+
} );
|
17782 |
+
|
17783 |
+
|
17784 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
17785 |
+
* DataTables API
|
17786 |
+
*
|
17787 |
+
* For complete documentation, please refer to the docs/api directory or the
|
17788 |
+
* DataTables site
|
17789 |
+
*/
|
17790 |
+
|
17791 |
+
// Buttons group and individual button selector
|
17792 |
+
DataTable.Api.register( 'buttons()', function ( group, selector ) {
|
17793 |
+
// Argument shifting
|
17794 |
+
if ( selector === undefined ) {
|
17795 |
+
selector = group;
|
17796 |
+
group = undefined;
|
17797 |
+
}
|
17798 |
+
|
17799 |
+
this.selector.buttonGroup = group;
|
17800 |
+
|
17801 |
+
var res = this.iterator( true, 'table', function ( ctx ) {
|
17802 |
+
if ( ctx._buttons ) {
|
17803 |
+
return Buttons.buttonSelector(
|
17804 |
+
Buttons.instanceSelector( group, ctx._buttons ),
|
17805 |
+
selector
|
17806 |
+
);
|
17807 |
+
}
|
17808 |
+
}, true );
|
17809 |
+
|
17810 |
+
res._groupSelector = group;
|
17811 |
+
return res;
|
17812 |
+
} );
|
17813 |
+
|
17814 |
+
// Individual button selector
|
17815 |
+
DataTable.Api.register( 'button()', function ( group, selector ) {
|
17816 |
+
// just run buttons() and truncate
|
17817 |
+
var buttons = this.buttons( group, selector );
|
17818 |
+
|
17819 |
+
if ( buttons.length > 1 ) {
|
17820 |
+
buttons.splice( 1, buttons.length );
|
17821 |
+
}
|
17822 |
+
|
17823 |
+
return buttons;
|
17824 |
+
} );
|
17825 |
+
|
17826 |
+
// Active buttons
|
17827 |
+
DataTable.Api.registerPlural( 'buttons().active()', 'button().active()', function ( flag ) {
|
17828 |
+
if ( flag === undefined ) {
|
17829 |
+
return this.map( function ( set ) {
|
17830 |
+
return set.inst.active( set.node );
|
17831 |
+
} );
|
17832 |
+
}
|
17833 |
+
|
17834 |
+
return this.each( function ( set ) {
|
17835 |
+
set.inst.active( set.node, flag );
|
17836 |
+
} );
|
17837 |
+
} );
|
17838 |
+
|
17839 |
+
// Get / set button action
|
17840 |
+
DataTable.Api.registerPlural( 'buttons().action()', 'button().action()', function ( action ) {
|
17841 |
+
if ( action === undefined ) {
|
17842 |
+
return this.map( function ( set ) {
|
17843 |
+
return set.inst.action( set.node );
|
17844 |
+
} );
|
17845 |
+
}
|
17846 |
+
|
17847 |
+
return this.each( function ( set ) {
|
17848 |
+
set.inst.action( set.node, action );
|
17849 |
+
} );
|
17850 |
+
} );
|
17851 |
+
|
17852 |
+
// Enable / disable buttons
|
17853 |
+
DataTable.Api.register( ['buttons().enable()', 'button().enable()'], function ( flag ) {
|
17854 |
+
return this.each( function ( set ) {
|
17855 |
+
set.inst.enable( set.node, flag );
|
17856 |
+
} );
|
17857 |
+
} );
|
17858 |
+
|
17859 |
+
// Disable buttons
|
17860 |
+
DataTable.Api.register( ['buttons().disable()', 'button().disable()'], function () {
|
17861 |
+
return this.each( function ( set ) {
|
17862 |
+
set.inst.disable( set.node );
|
17863 |
+
} );
|
17864 |
+
} );
|
17865 |
+
|
17866 |
+
// Get button nodes
|
17867 |
+
DataTable.Api.registerPlural( 'buttons().nodes()', 'button().node()', function () {
|
17868 |
+
var jq = $();
|
17869 |
+
|
17870 |
+
// jQuery will automatically reduce duplicates to a single entry
|
17871 |
+
$( this.each( function ( set ) {
|
17872 |
+
jq = jq.add( set.inst.node( set.node ) );
|
17873 |
+
} ) );
|
17874 |
+
|
17875 |
+
return jq;
|
17876 |
+
} );
|
17877 |
+
|
17878 |
+
// Get / set button processing state
|
17879 |
+
DataTable.Api.registerPlural( 'buttons().processing()', 'button().processing()', function ( flag ) {
|
17880 |
+
if ( flag === undefined ) {
|
17881 |
+
return this.map( function ( set ) {
|
17882 |
+
return set.inst.processing( set.node );
|
17883 |
+
} );
|
17884 |
+
}
|
17885 |
+
|
17886 |
+
return this.each( function ( set ) {
|
17887 |
+
set.inst.processing( set.node, flag );
|
17888 |
+
} );
|
17889 |
+
} );
|
17890 |
+
|
17891 |
+
// Get / set button text (i.e. the button labels)
|
17892 |
+
DataTable.Api.registerPlural( 'buttons().text()', 'button().text()', function ( label ) {
|
17893 |
+
if ( label === undefined ) {
|
17894 |
+
return this.map( function ( set ) {
|
17895 |
+
return set.inst.text( set.node );
|
17896 |
+
} );
|
17897 |
+
}
|
17898 |
+
|
17899 |
+
return this.each( function ( set ) {
|
17900 |
+
set.inst.text( set.node, label );
|
17901 |
+
} );
|
17902 |
+
} );
|
17903 |
+
|
17904 |
+
// Trigger a button's action
|
17905 |
+
DataTable.Api.registerPlural( 'buttons().trigger()', 'button().trigger()', function () {
|
17906 |
+
return this.each( function ( set ) {
|
17907 |
+
set.inst.node( set.node ).trigger( 'click' );
|
17908 |
+
} );
|
17909 |
+
} );
|
17910 |
+
|
17911 |
+
// Get the container elements
|
17912 |
+
DataTable.Api.registerPlural( 'buttons().containers()', 'buttons().container()', function () {
|
17913 |
+
var jq = $();
|
17914 |
+
var groupSelector = this._groupSelector;
|
17915 |
+
|
17916 |
+
// We need to use the group selector directly, since if there are no buttons
|
17917 |
+
// the result set will be empty
|
17918 |
+
this.iterator( true, 'table', function ( ctx ) {
|
17919 |
+
if ( ctx._buttons ) {
|
17920 |
+
var insts = Buttons.instanceSelector( groupSelector, ctx._buttons );
|
17921 |
+
|
17922 |
+
for ( var i=0, ien=insts.length ; i<ien ; i++ ) {
|
17923 |
+
jq = jq.add( insts[i].container() );
|
17924 |
+
}
|
17925 |
+
}
|
17926 |
+
} );
|
17927 |
+
|
17928 |
+
return jq;
|
17929 |
+
} );
|
17930 |
+
|
17931 |
+
// Add a new button
|
17932 |
+
DataTable.Api.register( 'button().add()', function ( idx, conf ) {
|
17933 |
+
var ctx = this.context;
|
17934 |
+
|
17935 |
+
// Don't use `this` as it could be empty - select the instances directly
|
17936 |
+
if ( ctx.length ) {
|
17937 |
+
var inst = Buttons.instanceSelector( this._groupSelector, ctx[0]._buttons );
|
17938 |
+
|
17939 |
+
if ( inst.length ) {
|
17940 |
+
inst[0].add( conf, idx );
|
17941 |
+
}
|
17942 |
+
}
|
17943 |
+
|
17944 |
+
return this.button( this._groupSelector, idx );
|
17945 |
+
} );
|
17946 |
+
|
17947 |
+
// Destroy the button sets selected
|
17948 |
+
DataTable.Api.register( 'buttons().destroy()', function () {
|
17949 |
+
this.pluck( 'inst' ).unique().each( function ( inst ) {
|
17950 |
+
inst.destroy();
|
17951 |
+
} );
|
17952 |
+
|
17953 |
+
return this;
|
17954 |
+
} );
|
17955 |
+
|
17956 |
+
// Remove a button
|
17957 |
+
DataTable.Api.registerPlural( 'buttons().remove()', 'buttons().remove()', function () {
|
17958 |
+
this.each( function ( set ) {
|
17959 |
+
set.inst.remove( set.node );
|
17960 |
+
} );
|
17961 |
+
|
17962 |
+
return this;
|
17963 |
+
} );
|
17964 |
+
|
17965 |
+
// Information box that can be used by buttons
|
17966 |
+
var _infoTimer;
|
17967 |
+
DataTable.Api.register( 'buttons.info()', function ( title, message, time ) {
|
17968 |
+
var that = this;
|
17969 |
+
|
17970 |
+
if ( title === false ) {
|
17971 |
+
$('#datatables_buttons_info').fadeOut( function () {
|
17972 |
+
$(this).remove();
|
17973 |
+
} );
|
17974 |
+
clearTimeout( _infoTimer );
|
17975 |
+
_infoTimer = null;
|
17976 |
+
|
17977 |
+
return this;
|
17978 |
+
}
|
17979 |
+
|
17980 |
+
if ( _infoTimer ) {
|
17981 |
+
clearTimeout( _infoTimer );
|
17982 |
+
}
|
17983 |
+
|
17984 |
+
if ( $('#datatables_buttons_info').length ) {
|
17985 |
+
$('#datatables_buttons_info').remove();
|
17986 |
+
}
|
17987 |
+
|
17988 |
+
title = title ? '<h2>'+title+'</h2>' : '';
|
17989 |
+
|
17990 |
+
$('<div id="datatables_buttons_info" class="dt-button-info"/>')
|
17991 |
+
.html( title )
|
17992 |
+
.append( $('<div/>')[ typeof message === 'string' ? 'html' : 'append' ]( message ) )
|
17993 |
+
.css( 'display', 'none' )
|
17994 |
+
.appendTo( 'body' )
|
17995 |
+
.fadeIn();
|
17996 |
+
|
17997 |
+
if ( time !== undefined && time !== 0 ) {
|
17998 |
+
_infoTimer = setTimeout( function () {
|
17999 |
+
that.buttons.info( false );
|
18000 |
+
}, time );
|
18001 |
+
}
|
18002 |
+
|
18003 |
+
return this;
|
18004 |
+
} );
|
18005 |
+
|
18006 |
+
// Get data from the table for export - this is common to a number of plug-in
|
18007 |
+
// buttons so it is included in the Buttons core library
|
18008 |
+
DataTable.Api.register( 'buttons.exportData()', function ( options ) {
|
18009 |
+
if ( this.context.length ) {
|
18010 |
+
return _exportData( new DataTable.Api( this.context[0] ), options );
|
18011 |
+
}
|
18012 |
+
} );
|
18013 |
+
|
18014 |
+
// Get information about the export that is common to many of the export data
|
18015 |
+
// types (DRY)
|
18016 |
+
DataTable.Api.register( 'buttons.exportInfo()', function ( conf ) {
|
18017 |
+
if ( ! conf ) {
|
18018 |
+
conf = {};
|
18019 |
+
}
|
18020 |
+
|
18021 |
+
return {
|
18022 |
+
filename: _filename( conf ),
|
18023 |
+
title: _title( conf ),
|
18024 |
+
messageTop: _message(this, conf.message || conf.messageTop, 'top'),
|
18025 |
+
messageBottom: _message(this, conf.messageBottom, 'bottom')
|
18026 |
+
};
|
18027 |
+
} );
|
18028 |
+
|
18029 |
+
|
18030 |
+
|
18031 |
+
/**
|
18032 |
+
* Get the file name for an exported file.
|
18033 |
+
*
|
18034 |
+
* @param {object} config Button configuration
|
18035 |
+
* @param {boolean} incExtension Include the file name extension
|
18036 |
+
*/
|
18037 |
+
var _filename = function ( config )
|
18038 |
+
{
|
18039 |
+
// Backwards compatibility
|
18040 |
+
var filename = config.filename === '*' && config.title !== '*' && config.title !== undefined && config.title !== null && config.title !== '' ?
|
18041 |
+
config.title :
|
18042 |
+
config.filename;
|
18043 |
+
|
18044 |
+
if ( typeof filename === 'function' ) {
|
18045 |
+
filename = filename();
|
18046 |
+
}
|
18047 |
+
|
18048 |
+
if ( filename === undefined || filename === null ) {
|
18049 |
+
return null;
|
18050 |
+
}
|
18051 |
+
|
18052 |
+
if ( filename.indexOf( '*' ) !== -1 ) {
|
18053 |
+
filename = $.trim( filename.replace( '*', $('head > title').text() ) );
|
18054 |
+
}
|
18055 |
+
|
18056 |
+
// Strip characters which the OS will object to
|
18057 |
+
filename = filename.replace(/[^a-zA-Z0-9_\u00A1-\uFFFF\.,\-_ !\(\)]/g, "");
|
18058 |
+
|
18059 |
+
var extension = _stringOrFunction( config.extension );
|
18060 |
+
if ( ! extension ) {
|
18061 |
+
extension = '';
|
18062 |
+
}
|
18063 |
+
|
18064 |
+
return filename + extension;
|
18065 |
+
};
|
18066 |
+
|
18067 |
+
/**
|
18068 |
+
* Simply utility method to allow parameters to be given as a function
|
18069 |
+
*
|
18070 |
+
* @param {undefined|string|function} option Option
|
18071 |
+
* @return {null|string} Resolved value
|
18072 |
+
*/
|
18073 |
+
var _stringOrFunction = function ( option )
|
18074 |
+
{
|
18075 |
+
if ( option === null || option === undefined ) {
|
18076 |
+
return null;
|
18077 |
+
}
|
18078 |
+
else if ( typeof option === 'function' ) {
|
18079 |
+
return option();
|
18080 |
+
}
|
18081 |
+
return option;
|
18082 |
+
};
|
18083 |
+
|
18084 |
+
/**
|
18085 |
+
* Get the title for an exported file.
|
18086 |
+
*
|
18087 |
+
* @param {object} config Button configuration
|
18088 |
+
*/
|
18089 |
+
var _title = function ( config )
|
18090 |
+
{
|
18091 |
+
var title = _stringOrFunction( config.title );
|
18092 |
+
|
18093 |
+
return title === null ?
|
18094 |
+
null : title.indexOf( '*' ) !== -1 ?
|
18095 |
+
title.replace( '*', $('head > title').text() || 'Exported data' ) :
|
18096 |
+
title;
|
18097 |
+
};
|
18098 |
+
|
18099 |
+
var _message = function ( dt, option, position )
|
18100 |
+
{
|
18101 |
+
var message = _stringOrFunction( option );
|
18102 |
+
if ( message === null ) {
|
18103 |
+
return null;
|
18104 |
+
}
|
18105 |
+
|
18106 |
+
var caption = $('caption', dt.table().container()).eq(0);
|
18107 |
+
if ( message === '*' ) {
|
18108 |
+
var side = caption.css( 'caption-side' );
|
18109 |
+
if ( side !== position ) {
|
18110 |
+
return null;
|
18111 |
+
}
|
18112 |
+
|
18113 |
+
return caption.length ?
|
18114 |
+
caption.text() :
|
18115 |
+
'';
|
18116 |
+
}
|
18117 |
+
|
18118 |
+
return message;
|
18119 |
+
};
|
18120 |
+
|
18121 |
+
|
18122 |
+
|
18123 |
+
|
18124 |
+
|
18125 |
+
|
18126 |
+
|
18127 |
+
var _exportTextarea = $('<textarea/>')[0];
|
18128 |
+
var _exportData = function ( dt, inOpts )
|
18129 |
+
{
|
18130 |
+
var config = $.extend( true, {}, {
|
18131 |
+
rows: null,
|
18132 |
+
columns: '',
|
18133 |
+
modifier: {
|
18134 |
+
search: 'applied',
|
18135 |
+
order: 'applied'
|
18136 |
+
},
|
18137 |
+
orthogonal: 'display',
|
18138 |
+
stripHtml: true,
|
18139 |
+
stripNewlines: true,
|
18140 |
+
decodeEntities: true,
|
18141 |
+
trim: true,
|
18142 |
+
format: {
|
18143 |
+
header: function ( d ) {
|
18144 |
+
return strip( d );
|
18145 |
+
},
|
18146 |
+
footer: function ( d ) {
|
18147 |
+
return strip( d );
|
18148 |
+
},
|
18149 |
+
body: function ( d ) {
|
18150 |
+
return strip( d );
|
18151 |
+
}
|
18152 |
+
}
|
18153 |
+
}, inOpts );
|
18154 |
+
|
18155 |
+
var strip = function ( str ) {
|
18156 |
+
if ( typeof str !== 'string' ) {
|
18157 |
+
return str;
|
18158 |
+
}
|
18159 |
+
|
18160 |
+
// Always remove script tags
|
18161 |
+
str = str.replace( /<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi, '' );
|
18162 |
+
|
18163 |
+
if ( config.stripHtml ) {
|
18164 |
+
str = str.replace( /<[^>]*>/g, '' );
|
18165 |
+
}
|
18166 |
+
|
18167 |
+
if ( config.trim ) {
|
18168 |
+
str = str.replace( /^\s+|\s+$/g, '' );
|
18169 |
+
}
|
18170 |
+
|
18171 |
+
if ( config.stripNewlines ) {
|
18172 |
+
str = str.replace( /\n/g, ' ' );
|
18173 |
+
}
|
18174 |
+
|
18175 |
+
if ( config.decodeEntities ) {
|
18176 |
+
_exportTextarea.innerHTML = str;
|
18177 |
+
str = _exportTextarea.value;
|
18178 |
+
}
|
18179 |
+
|
18180 |
+
return str;
|
18181 |
+
};
|
18182 |
+
|
18183 |
+
|
18184 |
+
var header = dt.columns( config.columns ).indexes().map( function (idx) {
|
18185 |
+
var el = dt.column( idx ).header();
|
18186 |
+
return config.format.header( el.innerHTML, idx, el );
|
18187 |
+
} ).toArray();
|
18188 |
+
|
18189 |
+
var footer = dt.table().footer() ?
|
18190 |
+
dt.columns( config.columns ).indexes().map( function (idx) {
|
18191 |
+
var el = dt.column( idx ).footer();
|
18192 |
+
return config.format.footer( el ? el.innerHTML : '', idx, el );
|
18193 |
+
} ).toArray() :
|
18194 |
+
null;
|
18195 |
+
|
18196 |
+
// If Select is available on this table, and any rows are selected, limit the export
|
18197 |
+
// to the selected rows. If no rows are selected, all rows will be exported. Specify
|
18198 |
+
// a `selected` modifier to control directly.
|
18199 |
+
var modifier = $.extend( {}, config.modifier );
|
18200 |
+
if ( dt.select && typeof dt.select.info === 'function' && modifier.selected === undefined ) {
|
18201 |
+
if ( dt.rows( config.rows, $.extend( { selected: true }, modifier ) ).any() ) {
|
18202 |
+
$.extend( modifier, { selected: true } )
|
18203 |
+
}
|
18204 |
+
}
|
18205 |
+
|
18206 |
+
var rowIndexes = dt.rows( config.rows, modifier ).indexes().toArray();
|
18207 |
+
var selectedCells = dt.cells( rowIndexes, config.columns );
|
18208 |
+
var cells = selectedCells
|
18209 |
+
.render( config.orthogonal )
|
18210 |
+
.toArray();
|
18211 |
+
var cellNodes = selectedCells
|
18212 |
+
.nodes()
|
18213 |
+
.toArray();
|
18214 |
+
|
18215 |
+
var columns = header.length;
|
18216 |
+
var rows = columns > 0 ? cells.length / columns : 0;
|
18217 |
+
var body = [ rows ];
|
18218 |
+
var cellCounter = 0;
|
18219 |
+
|
18220 |
+
for ( var i=0, ien=rows ; i<ien ; i++ ) {
|
18221 |
+
var row = [ columns ];
|
18222 |
+
|
18223 |
+
for ( var j=0 ; j<columns ; j++ ) {
|
18224 |
+
row[j] = config.format.body( cells[ cellCounter ], i, j, cellNodes[ cellCounter ] );
|
18225 |
+
cellCounter++;
|
18226 |
+
}
|
18227 |
+
|
18228 |
+
body[i] = row;
|
18229 |
+
}
|
18230 |
+
|
18231 |
+
return {
|
18232 |
+
header: header,
|
18233 |
+
footer: footer,
|
18234 |
+
body: body
|
18235 |
+
};
|
18236 |
+
};
|
18237 |
+
|
18238 |
+
|
18239 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
18240 |
+
* DataTables interface
|
18241 |
+
*/
|
18242 |
+
|
18243 |
+
// Attach to DataTables objects for global access
|
18244 |
+
$.fn.dataTable.Buttons = Buttons;
|
18245 |
+
$.fn.DataTable.Buttons = Buttons;
|
18246 |
+
|
18247 |
+
|
18248 |
+
|
18249 |
+
// DataTables creation - check if the buttons have been defined for this table,
|
18250 |
+
// they will have been if the `B` option was used in `dom`, otherwise we should
|
18251 |
+
// create the buttons instance here so they can be inserted into the document
|
18252 |
+
// using the API. Listen for `init` for compatibility with pre 1.10.10, but to
|
18253 |
+
// be removed in future.
|
18254 |
+
$(document).on( 'init.dt plugin-init.dt', function (e, settings) {
|
18255 |
+
if ( e.namespace !== 'dt' ) {
|
18256 |
+
return;
|
18257 |
+
}
|
18258 |
+
|
18259 |
+
var opts = settings.oInit.buttons || DataTable.defaults.buttons;
|
18260 |
+
|
18261 |
+
if ( opts && ! settings._buttons ) {
|
18262 |
+
new Buttons( settings, opts ).container();
|
18263 |
+
}
|
18264 |
+
} );
|
18265 |
+
|
18266 |
+
// DataTables `dom` feature option
|
18267 |
+
DataTable.ext.feature.push( {
|
18268 |
+
fnInit: function( settings ) {
|
18269 |
+
var api = new DataTable.Api( settings );
|
18270 |
+
var opts = api.init().buttons || DataTable.defaults.buttons;
|
18271 |
+
|
18272 |
+
return new Buttons( api, opts ).container();
|
18273 |
+
},
|
18274 |
+
cFeature: "B"
|
18275 |
+
} );
|
18276 |
+
|
18277 |
+
|
18278 |
+
return Buttons;
|
18279 |
+
}));
|
18280 |
+
|
18281 |
+
|
18282 |
+
/*! ColReorder 1.4.1
|
18283 |
+
* ©2010-2017 SpryMedia Ltd - datatables.net/license
|
18284 |
+
*/
|
18285 |
+
|
18286 |
+
/**
|
18287 |
+
* @summary ColReorder
|
18288 |
+
* @description Provide the ability to reorder columns in a DataTable
|
18289 |
+
* @version 1.4.1
|
18290 |
+
* @file dataTables.colReorder.js
|
18291 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
18292 |
+
* @contact www.sprymedia.co.uk/contact
|
18293 |
+
* @copyright Copyright 2010-2017 SpryMedia Ltd.
|
18294 |
+
*
|
18295 |
+
* This source file is free software, available under the following license:
|
18296 |
+
* MIT license - http://datatables.net/license/mit
|
18297 |
+
*
|
18298 |
+
* This source file is distributed in the hope that it will be useful, but
|
18299 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
18300 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
18301 |
+
*
|
18302 |
+
* For details please refer to: http://www.datatables.net
|
18303 |
+
*/
|
18304 |
+
(function( factory ){
|
18305 |
+
if ( typeof define === 'function' && define.amd ) {
|
18306 |
+
// AMD
|
18307 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
18308 |
+
return factory( $, window, document );
|
18309 |
+
} );
|
18310 |
+
}
|
18311 |
+
else if ( typeof exports === 'object' ) {
|
18312 |
+
// CommonJS
|
18313 |
+
module.exports = function (root, $) {
|
18314 |
+
if ( ! root ) {
|
18315 |
+
root = window;
|
18316 |
+
}
|
18317 |
+
|
18318 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
18319 |
+
$ = require('datatables.net')(root, $).$;
|
18320 |
+
}
|
18321 |
+
|
18322 |
+
return factory( $, root, root.document );
|
18323 |
+
};
|
18324 |
+
}
|
18325 |
+
else {
|
18326 |
+
// Browser
|
18327 |
+
factory( jQuery, window, document );
|
18328 |
+
}
|
18329 |
+
}(function( $, window, document, undefined ) {
|
18330 |
+
'use strict';
|
18331 |
+
var DataTable = $.fn.dataTable;
|
18332 |
+
|
18333 |
+
|
18334 |
+
/**
|
18335 |
+
* Switch the key value pairing of an index array to be value key (i.e. the old value is now the
|
18336 |
+
* key). For example consider [ 2, 0, 1 ] this would be returned as [ 1, 2, 0 ].
|
18337 |
+
* @method fnInvertKeyValues
|
18338 |
+
* @param array aIn Array to switch around
|
18339 |
+
* @returns array
|
18340 |
+
*/
|
18341 |
+
function fnInvertKeyValues( aIn )
|
18342 |
+
{
|
18343 |
+
var aRet=[];
|
18344 |
+
for ( var i=0, iLen=aIn.length ; i<iLen ; i++ )
|
18345 |
+
{
|
18346 |
+
aRet[ aIn[i] ] = i;
|
18347 |
+
}
|
18348 |
+
return aRet;
|
18349 |
+
}
|
18350 |
+
|
18351 |
+
|
18352 |
+
/**
|
18353 |
+
* Modify an array by switching the position of two elements
|
18354 |
+
* @method fnArraySwitch
|
18355 |
+
* @param array aArray Array to consider, will be modified by reference (i.e. no return)
|
18356 |
+
* @param int iFrom From point
|
18357 |
+
* @param int iTo Insert point
|
18358 |
+
* @returns void
|
18359 |
+
*/
|
18360 |
+
function fnArraySwitch( aArray, iFrom, iTo )
|
18361 |
+
{
|
18362 |
+
var mStore = aArray.splice( iFrom, 1 )[0];
|
18363 |
+
aArray.splice( iTo, 0, mStore );
|
18364 |
+
}
|
18365 |
+
|
18366 |
+
|
18367 |
+
/**
|
18368 |
+
* Switch the positions of nodes in a parent node (note this is specifically designed for
|
18369 |
+
* table rows). Note this function considers all element nodes under the parent!
|
18370 |
+
* @method fnDomSwitch
|
18371 |
+
* @param string sTag Tag to consider
|
18372 |
+
* @param int iFrom Element to move
|
18373 |
+
* @param int Point to element the element to (before this point), can be null for append
|
18374 |
+
* @returns void
|
18375 |
+
*/
|
18376 |
+
function fnDomSwitch( nParent, iFrom, iTo )
|
18377 |
+
{
|
18378 |
+
var anTags = [];
|
18379 |
+
for ( var i=0, iLen=nParent.childNodes.length ; i<iLen ; i++ )
|
18380 |
+
{
|
18381 |
+
if ( nParent.childNodes[i].nodeType == 1 )
|
18382 |
+
{
|
18383 |
+
anTags.push( nParent.childNodes[i] );
|
18384 |
+
}
|
18385 |
+
}
|
18386 |
+
var nStore = anTags[ iFrom ];
|
18387 |
+
|
18388 |
+
if ( iTo !== null )
|
18389 |
+
{
|
18390 |
+
nParent.insertBefore( nStore, anTags[iTo] );
|
18391 |
+
}
|
18392 |
+
else
|
18393 |
+
{
|
18394 |
+
nParent.appendChild( nStore );
|
18395 |
+
}
|
18396 |
+
}
|
18397 |
+
|
18398 |
+
|
18399 |
+
/**
|
18400 |
+
* Plug-in for DataTables which will reorder the internal column structure by taking the column
|
18401 |
+
* from one position (iFrom) and insert it into a given point (iTo).
|
18402 |
+
* @method $.fn.dataTableExt.oApi.fnColReorder
|
18403 |
+
* @param object oSettings DataTables settings object - automatically added by DataTables!
|
18404 |
+
* @param int iFrom Take the column to be repositioned from this point
|
18405 |
+
* @param int iTo and insert it into this point
|
18406 |
+
* @param bool drop Indicate if the reorder is the final one (i.e. a drop)
|
18407 |
+
* not a live reorder
|
18408 |
+
* @param bool invalidateRows speeds up processing if false passed
|
18409 |
+
* @returns void
|
18410 |
+
*/
|
18411 |
+
$.fn.dataTableExt.oApi.fnColReorder = function ( oSettings, iFrom, iTo, drop, invalidateRows )
|
18412 |
+
{
|
18413 |
+
var i, iLen, j, jLen, jen, iCols=oSettings.aoColumns.length, nTrs, oCol;
|
18414 |
+
var attrMap = function ( obj, prop, mapping ) {
|
18415 |
+
if ( ! obj[ prop ] || typeof obj[ prop ] === 'function' ) {
|
18416 |
+
return;
|
18417 |
+
}
|
18418 |
+
|
18419 |
+
var a = obj[ prop ].split('.');
|
18420 |
+
var num = a.shift();
|
18421 |
+
|
18422 |
+
if ( isNaN( num*1 ) ) {
|
18423 |
+
return;
|
18424 |
+
}
|
18425 |
+
|
18426 |
+
obj[ prop ] = mapping[ num*1 ]+'.'+a.join('.');
|
18427 |
+
};
|
18428 |
+
|
18429 |
+
/* Sanity check in the input */
|
18430 |
+
if ( iFrom == iTo )
|
18431 |
+
{
|
18432 |
+
/* Pointless reorder */
|
18433 |
+
return;
|
18434 |
+
}
|
18435 |
+
|
18436 |
+
if ( iFrom < 0 || iFrom >= iCols )
|
18437 |
+
{
|
18438 |
+
this.oApi._fnLog( oSettings, 1, "ColReorder 'from' index is out of bounds: "+iFrom );
|
18439 |
+
return;
|
18440 |
+
}
|
18441 |
+
|
18442 |
+
if ( iTo < 0 || iTo >= iCols )
|
18443 |
+
{
|
18444 |
+
this.oApi._fnLog( oSettings, 1, "ColReorder 'to' index is out of bounds: "+iTo );
|
18445 |
+
return;
|
18446 |
+
}
|
18447 |
+
|
18448 |
+
/*
|
18449 |
+
* Calculate the new column array index, so we have a mapping between the old and new
|
18450 |
+
*/
|
18451 |
+
var aiMapping = [];
|
18452 |
+
for ( i=0, iLen=iCols ; i<iLen ; i++ )
|
18453 |
+
{
|
18454 |
+
aiMapping[i] = i;
|
18455 |
+
}
|
18456 |
+
fnArraySwitch( aiMapping, iFrom, iTo );
|
18457 |
+
var aiInvertMapping = fnInvertKeyValues( aiMapping );
|
18458 |
+
|
18459 |
+
|
18460 |
+
/*
|
18461 |
+
* Convert all internal indexing to the new column order indexes
|
18462 |
+
*/
|
18463 |
+
/* Sorting */
|
18464 |
+
for ( i=0, iLen=oSettings.aaSorting.length ; i<iLen ; i++ )
|
18465 |
+
{
|
18466 |
+
oSettings.aaSorting[i][0] = aiInvertMapping[ oSettings.aaSorting[i][0] ];
|
18467 |
+
}
|
18468 |
+
|
18469 |
+
/* Fixed sorting */
|
18470 |
+
if ( oSettings.aaSortingFixed !== null )
|
18471 |
+
{
|
18472 |
+
for ( i=0, iLen=oSettings.aaSortingFixed.length ; i<iLen ; i++ )
|
18473 |
+
{
|
18474 |
+
oSettings.aaSortingFixed[i][0] = aiInvertMapping[ oSettings.aaSortingFixed[i][0] ];
|
18475 |
+
}
|
18476 |
+
}
|
18477 |
+
|
18478 |
+
/* Data column sorting (the column which the sort for a given column should take place on) */
|
18479 |
+
for ( i=0, iLen=iCols ; i<iLen ; i++ )
|
18480 |
+
{
|
18481 |
+
oCol = oSettings.aoColumns[i];
|
18482 |
+
for ( j=0, jLen=oCol.aDataSort.length ; j<jLen ; j++ )
|
18483 |
+
{
|
18484 |
+
oCol.aDataSort[j] = aiInvertMapping[ oCol.aDataSort[j] ];
|
18485 |
+
}
|
18486 |
+
|
18487 |
+
// Update the column indexes
|
18488 |
+
oCol.idx = aiInvertMapping[ oCol.idx ];
|
18489 |
+
}
|
18490 |
+
|
18491 |
+
// Update 1.10 optimised sort class removal variable
|
18492 |
+
$.each( oSettings.aLastSort, function (i, val) {
|
18493 |
+
oSettings.aLastSort[i].src = aiInvertMapping[ val.src ];
|
18494 |
+
} );
|
18495 |
+
|
18496 |
+
/* Update the Get and Set functions for each column */
|
18497 |
+
for ( i=0, iLen=iCols ; i<iLen ; i++ )
|
18498 |
+
{
|
18499 |
+
oCol = oSettings.aoColumns[i];
|
18500 |
+
|
18501 |
+
if ( typeof oCol.mData == 'number' ) {
|
18502 |
+
oCol.mData = aiInvertMapping[ oCol.mData ];
|
18503 |
+
}
|
18504 |
+
else if ( $.isPlainObject( oCol.mData ) ) {
|
18505 |
+
// HTML5 data sourced
|
18506 |
+
attrMap( oCol.mData, '_', aiInvertMapping );
|
18507 |
+
attrMap( oCol.mData, 'filter', aiInvertMapping );
|
18508 |
+
attrMap( oCol.mData, 'sort', aiInvertMapping );
|
18509 |
+
attrMap( oCol.mData, 'type', aiInvertMapping );
|
18510 |
+
}
|
18511 |
+
}
|
18512 |
+
|
18513 |
+
/*
|
18514 |
+
* Move the DOM elements
|
18515 |
+
*/
|
18516 |
+
if ( oSettings.aoColumns[iFrom].bVisible )
|
18517 |
+
{
|
18518 |
+
/* Calculate the current visible index and the point to insert the node before. The insert
|
18519 |
+
* before needs to take into account that there might not be an element to insert before,
|
18520 |
+
* in which case it will be null, and an appendChild should be used
|
18521 |
+
*/
|
18522 |
+
var iVisibleIndex = this.oApi._fnColumnIndexToVisible( oSettings, iFrom );
|
18523 |
+
var iInsertBeforeIndex = null;
|
18524 |
+
|
18525 |
+
i = iTo < iFrom ? iTo : iTo + 1;
|
18526 |
+
while ( iInsertBeforeIndex === null && i < iCols )
|
18527 |
+
{
|
18528 |
+
iInsertBeforeIndex = this.oApi._fnColumnIndexToVisible( oSettings, i );
|
18529 |
+
i++;
|
18530 |
+
}
|
18531 |
+
|
18532 |
+
/* Header */
|
18533 |
+
nTrs = oSettings.nTHead.getElementsByTagName('tr');
|
18534 |
+
for ( i=0, iLen=nTrs.length ; i<iLen ; i++ )
|
18535 |
+
{
|
18536 |
+
fnDomSwitch( nTrs[i], iVisibleIndex, iInsertBeforeIndex );
|
18537 |
+
}
|
18538 |
+
|
18539 |
+
/* Footer */
|
18540 |
+
if ( oSettings.nTFoot !== null )
|
18541 |
+
{
|
18542 |
+
nTrs = oSettings.nTFoot.getElementsByTagName('tr');
|
18543 |
+
for ( i=0, iLen=nTrs.length ; i<iLen ; i++ )
|
18544 |
+
{
|
18545 |
+
fnDomSwitch( nTrs[i], iVisibleIndex, iInsertBeforeIndex );
|
18546 |
+
}
|
18547 |
+
}
|
18548 |
+
|
18549 |
+
/* Body */
|
18550 |
+
for ( i=0, iLen=oSettings.aoData.length ; i<iLen ; i++ )
|
18551 |
+
{
|
18552 |
+
if ( oSettings.aoData[i].nTr !== null )
|
18553 |
+
{
|
18554 |
+
fnDomSwitch( oSettings.aoData[i].nTr, iVisibleIndex, iInsertBeforeIndex );
|
18555 |
+
}
|
18556 |
+
}
|
18557 |
+
}
|
18558 |
+
|
18559 |
+
/*
|
18560 |
+
* Move the internal array elements
|
18561 |
+
*/
|
18562 |
+
/* Columns */
|
18563 |
+
fnArraySwitch( oSettings.aoColumns, iFrom, iTo );
|
18564 |
+
|
18565 |
+
// regenerate the get / set functions
|
18566 |
+
for ( i=0, iLen=iCols ; i<iLen ; i++ ) {
|
18567 |
+
oSettings.oApi._fnColumnOptions( oSettings, i, {} );
|
18568 |
+
}
|
18569 |
+
|
18570 |
+
/* Search columns */
|
18571 |
+
fnArraySwitch( oSettings.aoPreSearchCols, iFrom, iTo );
|
18572 |
+
|
18573 |
+
/* Array array - internal data anodes cache */
|
18574 |
+
for ( i=0, iLen=oSettings.aoData.length ; i<iLen ; i++ )
|
18575 |
+
{
|
18576 |
+
var data = oSettings.aoData[i];
|
18577 |
+
var cells = data.anCells;
|
18578 |
+
|
18579 |
+
if ( cells ) {
|
18580 |
+
fnArraySwitch( cells, iFrom, iTo );
|
18581 |
+
|
18582 |
+
// Longer term, should this be moved into the DataTables' invalidate
|
18583 |
+
// methods?
|
18584 |
+
for ( j=0, jen=cells.length ; j<jen ; j++ ) {
|
18585 |
+
if ( cells[j] && cells[j]._DT_CellIndex ) {
|
18586 |
+
cells[j]._DT_CellIndex.column = j;
|
18587 |
+
}
|
18588 |
+
}
|
18589 |
+
}
|
18590 |
+
|
18591 |
+
// For DOM sourced data, the invalidate will reread the cell into
|
18592 |
+
// the data array, but for data sources as an array, they need to
|
18593 |
+
// be flipped
|
18594 |
+
if ( data.src !== 'dom' && $.isArray( data._aData ) ) {
|
18595 |
+
fnArraySwitch( data._aData, iFrom, iTo );
|
18596 |
+
}
|
18597 |
+
}
|
18598 |
+
|
18599 |
+
/* Reposition the header elements in the header layout array */
|
18600 |
+
for ( i=0, iLen=oSettings.aoHeader.length ; i<iLen ; i++ )
|
18601 |
+
{
|
18602 |
+
fnArraySwitch( oSettings.aoHeader[i], iFrom, iTo );
|
18603 |
+
}
|
18604 |
+
|
18605 |
+
if ( oSettings.aoFooter !== null )
|
18606 |
+
{
|
18607 |
+
for ( i=0, iLen=oSettings.aoFooter.length ; i<iLen ; i++ )
|
18608 |
+
{
|
18609 |
+
fnArraySwitch( oSettings.aoFooter[i], iFrom, iTo );
|
18610 |
+
}
|
18611 |
+
}
|
18612 |
+
|
18613 |
+
if ( invalidateRows || invalidateRows === undefined )
|
18614 |
+
{
|
18615 |
+
$.fn.dataTable.Api( oSettings ).rows().invalidate();
|
18616 |
+
}
|
18617 |
+
|
18618 |
+
/*
|
18619 |
+
* Update DataTables' event handlers
|
18620 |
+
*/
|
18621 |
+
|
18622 |
+
/* Sort listener */
|
18623 |
+
for ( i=0, iLen=iCols ; i<iLen ; i++ )
|
18624 |
+
{
|
18625 |
+
$(oSettings.aoColumns[i].nTh).off('click.DT');
|
18626 |
+
this.oApi._fnSortAttachListener( oSettings, oSettings.aoColumns[i].nTh, i );
|
18627 |
+
}
|
18628 |
+
|
18629 |
+
|
18630 |
+
/* Fire an event so other plug-ins can update */
|
18631 |
+
$(oSettings.oInstance).trigger( 'column-reorder.dt', [ oSettings, {
|
18632 |
+
from: iFrom,
|
18633 |
+
to: iTo,
|
18634 |
+
mapping: aiInvertMapping,
|
18635 |
+
drop: drop,
|
18636 |
+
|
18637 |
+
// Old style parameters for compatibility
|
18638 |
+
iFrom: iFrom,
|
18639 |
+
iTo: iTo,
|
18640 |
+
aiInvertMapping: aiInvertMapping
|
18641 |
+
} ] );
|
18642 |
+
};
|
18643 |
+
|
18644 |
+
/**
|
18645 |
+
* ColReorder provides column visibility control for DataTables
|
18646 |
+
* @class ColReorder
|
18647 |
+
* @constructor
|
18648 |
+
* @param {object} dt DataTables settings object
|
18649 |
+
* @param {object} opts ColReorder options
|
18650 |
+
*/
|
18651 |
+
var ColReorder = function( dt, opts )
|
18652 |
+
{
|
18653 |
+
var settings = new $.fn.dataTable.Api( dt ).settings()[0];
|
18654 |
+
|
18655 |
+
// Ensure that we can't initialise on the same table twice
|
18656 |
+
if ( settings._colReorder ) {
|
18657 |
+
return settings._colReorder;
|
18658 |
+
}
|
18659 |
+
|
18660 |
+
// Allow the options to be a boolean for defaults
|
18661 |
+
if ( opts === true ) {
|
18662 |
+
opts = {};
|
18663 |
+
}
|
18664 |
+
|
18665 |
+
// Convert from camelCase to Hungarian, just as DataTables does
|
18666 |
+
var camelToHungarian = $.fn.dataTable.camelToHungarian;
|
18667 |
+
if ( camelToHungarian ) {
|
18668 |
+
camelToHungarian( ColReorder.defaults, ColReorder.defaults, true );
|
18669 |
+
camelToHungarian( ColReorder.defaults, opts || {} );
|
18670 |
+
}
|
18671 |
+
|
18672 |
+
|
18673 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
18674 |
+
* Public class variables
|
18675 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
18676 |
+
|
18677 |
+
/**
|
18678 |
+
* @namespace Settings object which contains customisable information for ColReorder instance
|
18679 |
+
*/
|
18680 |
+
this.s = {
|
18681 |
+
/**
|
18682 |
+
* DataTables settings object
|
18683 |
+
* @property dt
|
18684 |
+
* @type Object
|
18685 |
+
* @default null
|
18686 |
+
*/
|
18687 |
+
"dt": null,
|
18688 |
+
|
18689 |
+
/**
|
18690 |
+
* Initialisation object used for this instance
|
18691 |
+
* @property init
|
18692 |
+
* @type object
|
18693 |
+
* @default {}
|
18694 |
+
*/
|
18695 |
+
"init": $.extend( true, {}, ColReorder.defaults, opts ),
|
18696 |
+
|
18697 |
+
/**
|
18698 |
+
* Number of columns to fix (not allow to be reordered)
|
18699 |
+
* @property fixed
|
18700 |
+
* @type int
|
18701 |
+
* @default 0
|
18702 |
+
*/
|
18703 |
+
"fixed": 0,
|
18704 |
+
|
18705 |
+
/**
|
18706 |
+
* Number of columns to fix counting from right (not allow to be reordered)
|
18707 |
+
* @property fixedRight
|
18708 |
+
* @type int
|
18709 |
+
* @default 0
|
18710 |
+
*/
|
18711 |
+
"fixedRight": 0,
|
18712 |
+
|
18713 |
+
/**
|
18714 |
+
* Callback function for once the reorder has been done
|
18715 |
+
* @property reorderCallback
|
18716 |
+
* @type function
|
18717 |
+
* @default null
|
18718 |
+
*/
|
18719 |
+
"reorderCallback": null,
|
18720 |
+
|
18721 |
+
/**
|
18722 |
+
* @namespace Information used for the mouse drag
|
18723 |
+
*/
|
18724 |
+
"mouse": {
|
18725 |
+
"startX": -1,
|
18726 |
+
"startY": -1,
|
18727 |
+
"offsetX": -1,
|
18728 |
+
"offsetY": -1,
|
18729 |
+
"target": -1,
|
18730 |
+
"targetIndex": -1,
|
18731 |
+
"fromIndex": -1
|
18732 |
+
},
|
18733 |
+
|
18734 |
+
/**
|
18735 |
+
* Information which is used for positioning the insert cusor and knowing where to do the
|
18736 |
+
* insert. Array of objects with the properties:
|
18737 |
+
* x: x-axis position
|
18738 |
+
* to: insert point
|
18739 |
+
* @property aoTargets
|
18740 |
+
* @type array
|
18741 |
+
* @default []
|
18742 |
+
*/
|
18743 |
+
"aoTargets": []
|
18744 |
+
};
|
18745 |
+
|
18746 |
+
|
18747 |
+
/**
|
18748 |
+
* @namespace Common and useful DOM elements for the class instance
|
18749 |
+
*/
|
18750 |
+
this.dom = {
|
18751 |
+
/**
|
18752 |
+
* Dragging element (the one the mouse is moving)
|
18753 |
+
* @property drag
|
18754 |
+
* @type element
|
18755 |
+
* @default null
|
18756 |
+
*/
|
18757 |
+
"drag": null,
|
18758 |
+
|
18759 |
+
/**
|
18760 |
+
* The insert cursor
|
18761 |
+
* @property pointer
|
18762 |
+
* @type element
|
18763 |
+
* @default null
|
18764 |
+
*/
|
18765 |
+
"pointer": null
|
18766 |
+
};
|
18767 |
+
|
18768 |
+
|
18769 |
+
/* Constructor logic */
|
18770 |
+
this.s.dt = settings;
|
18771 |
+
this.s.dt._colReorder = this;
|
18772 |
+
this._fnConstruct();
|
18773 |
+
|
18774 |
+
return this;
|
18775 |
+
};
|
18776 |
+
|
18777 |
+
|
18778 |
+
|
18779 |
+
$.extend( ColReorder.prototype, {
|
18780 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
18781 |
+
* Public methods
|
18782 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
18783 |
+
|
18784 |
+
/**
|
18785 |
+
* Reset the column ordering to the original ordering that was detected on
|
18786 |
+
* start up.
|
18787 |
+
* @return {this} Returns `this` for chaining.
|
18788 |
+
*
|
18789 |
+
* @example
|
18790 |
+
* // DataTables initialisation with ColReorder
|
18791 |
+
* var table = $('#example').dataTable( {
|
18792 |
+
* "sDom": 'Rlfrtip'
|
18793 |
+
* } );
|
18794 |
+
*
|
18795 |
+
* // Add click event to a button to reset the ordering
|
18796 |
+
* $('#resetOrdering').click( function (e) {
|
18797 |
+
* e.preventDefault();
|
18798 |
+
* $.fn.dataTable.ColReorder( table ).fnReset();
|
18799 |
+
* } );
|
18800 |
+
*/
|
18801 |
+
"fnReset": function ()
|
18802 |
+
{
|
18803 |
+
this._fnOrderColumns( this.fnOrder() );
|
18804 |
+
|
18805 |
+
return this;
|
18806 |
+
},
|
18807 |
+
|
18808 |
+
/**
|
18809 |
+
* `Deprecated` - Get the current order of the columns, as an array.
|
18810 |
+
* @return {array} Array of column identifiers
|
18811 |
+
* @deprecated `fnOrder` should be used in preference to this method.
|
18812 |
+
* `fnOrder` acts as a getter/setter.
|
18813 |
+
*/
|
18814 |
+
"fnGetCurrentOrder": function ()
|
18815 |
+
{
|
18816 |
+
return this.fnOrder();
|
18817 |
+
},
|
18818 |
+
|
18819 |
+
/**
|
18820 |
+
* Get the current order of the columns, as an array. Note that the values
|
18821 |
+
* given in the array are unique identifiers for each column. Currently
|
18822 |
+
* these are the original ordering of the columns that was detected on
|
18823 |
+
* start up, but this could potentially change in future.
|
18824 |
+
* @return {array} Array of column identifiers
|
18825 |
+
*
|
18826 |
+
* @example
|
18827 |
+
* // Get column ordering for the table
|
18828 |
+
* var order = $.fn.dataTable.ColReorder( dataTable ).fnOrder();
|
18829 |
+
*//**
|
18830 |
+
* Set the order of the columns, from the positions identified in the
|
18831 |
+
* ordering array given. Note that ColReorder takes a brute force approach
|
18832 |
+
* to reordering, so it is possible multiple reordering events will occur
|
18833 |
+
* before the final order is settled upon.
|
18834 |
+
* @param {array} [set] Array of column identifiers in the new order. Note
|
18835 |
+
* that every column must be included, uniquely, in this array.
|
18836 |
+
* @return {this} Returns `this` for chaining.
|
18837 |
+
*
|
18838 |
+
* @example
|
18839 |
+
* // Swap the first and second columns
|
18840 |
+
* $.fn.dataTable.ColReorder( dataTable ).fnOrder( [1, 0, 2, 3, 4] );
|
18841 |
+
*
|
18842 |
+
* @example
|
18843 |
+
* // Move the first column to the end for the table `#example`
|
18844 |
+
* var curr = $.fn.dataTable.ColReorder( '#example' ).fnOrder();
|
18845 |
+
* var first = curr.shift();
|
18846 |
+
* curr.push( first );
|
18847 |
+
* $.fn.dataTable.ColReorder( '#example' ).fnOrder( curr );
|
18848 |
+
*
|
18849 |
+
* @example
|
18850 |
+
* // Reverse the table's order
|
18851 |
+
* $.fn.dataTable.ColReorder( '#example' ).fnOrder(
|
18852 |
+
* $.fn.dataTable.ColReorder( '#example' ).fnOrder().reverse()
|
18853 |
+
* );
|
18854 |
+
*/
|
18855 |
+
"fnOrder": function ( set, original )
|
18856 |
+
{
|
18857 |
+
var a = [], i, ien, j, jen;
|
18858 |
+
var columns = this.s.dt.aoColumns;
|
18859 |
+
|
18860 |
+
if ( set === undefined ){
|
18861 |
+
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
18862 |
+
a.push( columns[i]._ColReorder_iOrigCol );
|
18863 |
+
}
|
18864 |
+
|
18865 |
+
return a;
|
18866 |
+
}
|
18867 |
+
|
18868 |
+
// The order given is based on the original indexes, rather than the
|
18869 |
+
// existing ones, so we need to translate from the original to current
|
18870 |
+
// before then doing the order
|
18871 |
+
if ( original ) {
|
18872 |
+
var order = this.fnOrder();
|
18873 |
+
|
18874 |
+
for ( i=0, ien=set.length ; i<ien ; i++ ) {
|
18875 |
+
a.push( $.inArray( set[i], order ) );
|
18876 |
+
}
|
18877 |
+
|
18878 |
+
set = a;
|
18879 |
+
}
|
18880 |
+
|
18881 |
+
this._fnOrderColumns( fnInvertKeyValues( set ) );
|
18882 |
+
|
18883 |
+
return this;
|
18884 |
+
},
|
18885 |
+
|
18886 |
+
|
18887 |
+
/**
|
18888 |
+
* Convert from the original column index, to the original
|
18889 |
+
*
|
18890 |
+
* @param {int|array} idx Index(es) to convert
|
18891 |
+
* @param {string} dir Transpose direction - `fromOriginal` / `toCurrent`
|
18892 |
+
* or `'toOriginal` / `fromCurrent`
|
18893 |
+
* @return {int|array} Converted values
|
18894 |
+
*/
|
18895 |
+
fnTranspose: function ( idx, dir )
|
18896 |
+
{
|
18897 |
+
if ( ! dir ) {
|
18898 |
+
dir = 'toCurrent';
|
18899 |
+
}
|
18900 |
+
|
18901 |
+
var order = this.fnOrder();
|
18902 |
+
var columns = this.s.dt.aoColumns;
|
18903 |
+
|
18904 |
+
if ( dir === 'toCurrent' ) {
|
18905 |
+
// Given an original index, want the current
|
18906 |
+
return ! $.isArray( idx ) ?
|
18907 |
+
$.inArray( idx, order ) :
|
18908 |
+
$.map( idx, function ( index ) {
|
18909 |
+
return $.inArray( index, order );
|
18910 |
+
} );
|
18911 |
+
}
|
18912 |
+
else {
|
18913 |
+
// Given a current index, want the original
|
18914 |
+
return ! $.isArray( idx ) ?
|
18915 |
+
columns[idx]._ColReorder_iOrigCol :
|
18916 |
+
$.map( idx, function ( index ) {
|
18917 |
+
return columns[index]._ColReorder_iOrigCol;
|
18918 |
+
} );
|
18919 |
+
}
|
18920 |
+
},
|
18921 |
+
|
18922 |
+
|
18923 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
18924 |
+
* Private methods (they are of course public in JS, but recommended as private)
|
18925 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
18926 |
+
|
18927 |
+
/**
|
18928 |
+
* Constructor logic
|
18929 |
+
* @method _fnConstruct
|
18930 |
+
* @returns void
|
18931 |
+
* @private
|
18932 |
+
*/
|
18933 |
+
"_fnConstruct": function ()
|
18934 |
+
{
|
18935 |
+
var that = this;
|
18936 |
+
var iLen = this.s.dt.aoColumns.length;
|
18937 |
+
var table = this.s.dt.nTable;
|
18938 |
+
var i;
|
18939 |
+
|
18940 |
+
/* Columns discounted from reordering - counting left to right */
|
18941 |
+
if ( this.s.init.iFixedColumns )
|
18942 |
+
{
|
18943 |
+
this.s.fixed = this.s.init.iFixedColumns;
|
18944 |
+
}
|
18945 |
+
|
18946 |
+
if ( this.s.init.iFixedColumnsLeft )
|
18947 |
+
{
|
18948 |
+
this.s.fixed = this.s.init.iFixedColumnsLeft;
|
18949 |
+
}
|
18950 |
+
|
18951 |
+
/* Columns discounted from reordering - counting right to left */
|
18952 |
+
this.s.fixedRight = this.s.init.iFixedColumnsRight ?
|
18953 |
+
this.s.init.iFixedColumnsRight :
|
18954 |
+
0;
|
18955 |
+
|
18956 |
+
/* Drop callback initialisation option */
|
18957 |
+
if ( this.s.init.fnReorderCallback )
|
18958 |
+
{
|
18959 |
+
this.s.reorderCallback = this.s.init.fnReorderCallback;
|
18960 |
+
}
|
18961 |
+
|
18962 |
+
/* Add event handlers for the drag and drop, and also mark the original column order */
|
18963 |
+
for ( i = 0; i < iLen; i++ )
|
18964 |
+
{
|
18965 |
+
if ( i > this.s.fixed-1 && i < iLen - this.s.fixedRight )
|
18966 |
+
{
|
18967 |
+
this._fnMouseListener( i, this.s.dt.aoColumns[i].nTh );
|
18968 |
+
}
|
18969 |
+
|
18970 |
+
/* Mark the original column order for later reference */
|
18971 |
+
this.s.dt.aoColumns[i]._ColReorder_iOrigCol = i;
|
18972 |
+
}
|
18973 |
+
|
18974 |
+
/* State saving */
|
18975 |
+
this.s.dt.oApi._fnCallbackReg( this.s.dt, 'aoStateSaveParams', function (oS, oData) {
|
18976 |
+
that._fnStateSave.call( that, oData );
|
18977 |
+
}, "ColReorder_State" );
|
18978 |
+
|
18979 |
+
/* An initial column order has been specified */
|
18980 |
+
var aiOrder = null;
|
18981 |
+
if ( this.s.init.aiOrder )
|
18982 |
+
{
|
18983 |
+
aiOrder = this.s.init.aiOrder.slice();
|
18984 |
+
}
|
18985 |
+
|
18986 |
+
/* State loading, overrides the column order given */
|
18987 |
+
if ( this.s.dt.oLoadedState && typeof this.s.dt.oLoadedState.ColReorder != 'undefined' &&
|
18988 |
+
this.s.dt.oLoadedState.ColReorder.length == this.s.dt.aoColumns.length )
|
18989 |
+
{
|
18990 |
+
aiOrder = this.s.dt.oLoadedState.ColReorder;
|
18991 |
+
}
|
18992 |
+
|
18993 |
+
/* If we have an order to apply - do so */
|
18994 |
+
if ( aiOrder )
|
18995 |
+
{
|
18996 |
+
/* We might be called during or after the DataTables initialisation. If before, then we need
|
18997 |
+
* to wait until the draw is done, if after, then do what we need to do right away
|
18998 |
+
*/
|
18999 |
+
if ( !that.s.dt._bInitComplete )
|
19000 |
+
{
|
19001 |
+
var bDone = false;
|
19002 |
+
$(table).on( 'draw.dt.colReorder', function () {
|
19003 |
+
if ( !that.s.dt._bInitComplete && !bDone )
|
19004 |
+
{
|
19005 |
+
bDone = true;
|
19006 |
+
var resort = fnInvertKeyValues( aiOrder );
|
19007 |
+
that._fnOrderColumns.call( that, resort );
|
19008 |
+
}
|
19009 |
+
} );
|
19010 |
+
}
|
19011 |
+
else
|
19012 |
+
{
|
19013 |
+
var resort = fnInvertKeyValues( aiOrder );
|
19014 |
+
that._fnOrderColumns.call( that, resort );
|
19015 |
+
}
|
19016 |
+
}
|
19017 |
+
else {
|
19018 |
+
this._fnSetColumnIndexes();
|
19019 |
+
}
|
19020 |
+
|
19021 |
+
// Destroy clean up
|
19022 |
+
$(table).on( 'destroy.dt.colReorder', function () {
|
19023 |
+
$(table).off( 'destroy.dt.colReorder draw.dt.colReorder' );
|
19024 |
+
$(that.s.dt.nTHead).find( '*' ).off( '.ColReorder' );
|
19025 |
+
|
19026 |
+
$.each( that.s.dt.aoColumns, function (i, column) {
|
19027 |
+
$(column.nTh).removeAttr('data-column-index');
|
19028 |
+
} );
|
19029 |
+
|
19030 |
+
that.s.dt._colReorder = null;
|
19031 |
+
that.s = null;
|
19032 |
+
} );
|
19033 |
+
},
|
19034 |
+
|
19035 |
+
|
19036 |
+
/**
|
19037 |
+
* Set the column order from an array
|
19038 |
+
* @method _fnOrderColumns
|
19039 |
+
* @param array a An array of integers which dictate the column order that should be applied
|
19040 |
+
* @returns void
|
19041 |
+
* @private
|
19042 |
+
*/
|
19043 |
+
"_fnOrderColumns": function ( a )
|
19044 |
+
{
|
19045 |
+
var changed = false;
|
19046 |
+
|
19047 |
+
if ( a.length != this.s.dt.aoColumns.length )
|
19048 |
+
{
|
19049 |
+
this.s.dt.oInstance.oApi._fnLog( this.s.dt, 1, "ColReorder - array reorder does not "+
|
19050 |
+
"match known number of columns. Skipping." );
|
19051 |
+
return;
|
19052 |
+
}
|
19053 |
+
|
19054 |
+
for ( var i=0, iLen=a.length ; i<iLen ; i++ )
|
19055 |
+
{
|
19056 |
+
var currIndex = $.inArray( i, a );
|
19057 |
+
if ( i != currIndex )
|
19058 |
+
{
|
19059 |
+
/* Reorder our switching array */
|
19060 |
+
fnArraySwitch( a, currIndex, i );
|
19061 |
+
|
19062 |
+
/* Do the column reorder in the table */
|
19063 |
+
this.s.dt.oInstance.fnColReorder( currIndex, i, true, false );
|
19064 |
+
|
19065 |
+
changed = true;
|
19066 |
+
}
|
19067 |
+
}
|
19068 |
+
|
19069 |
+
$.fn.dataTable.Api( this.s.dt ).rows().invalidate();
|
19070 |
+
|
19071 |
+
this._fnSetColumnIndexes();
|
19072 |
+
|
19073 |
+
// Has anything actually changed? If not, then nothing else to do
|
19074 |
+
if ( ! changed ) {
|
19075 |
+
return;
|
19076 |
+
}
|
19077 |
+
|
19078 |
+
/* When scrolling we need to recalculate the column sizes to allow for the shift */
|
19079 |
+
if ( this.s.dt.oScroll.sX !== "" || this.s.dt.oScroll.sY !== "" )
|
19080 |
+
{
|
19081 |
+
this.s.dt.oInstance.fnAdjustColumnSizing( false );
|
19082 |
+
}
|
19083 |
+
|
19084 |
+
/* Save the state */
|
19085 |
+
this.s.dt.oInstance.oApi._fnSaveState( this.s.dt );
|
19086 |
+
|
19087 |
+
if ( this.s.reorderCallback !== null )
|
19088 |
+
{
|
19089 |
+
this.s.reorderCallback.call( this );
|
19090 |
+
}
|
19091 |
+
},
|
19092 |
+
|
19093 |
+
|
19094 |
+
/**
|
19095 |
+
* Because we change the indexes of columns in the table, relative to their starting point
|
19096 |
+
* we need to reorder the state columns to what they are at the starting point so we can
|
19097 |
+
* then rearrange them again on state load!
|
19098 |
+
* @method _fnStateSave
|
19099 |
+
* @param object oState DataTables state
|
19100 |
+
* @returns string JSON encoded cookie string for DataTables
|
19101 |
+
* @private
|
19102 |
+
*/
|
19103 |
+
"_fnStateSave": function ( oState )
|
19104 |
+
{
|
19105 |
+
var i, iLen, aCopy, iOrigColumn;
|
19106 |
+
var oSettings = this.s.dt;
|
19107 |
+
var columns = oSettings.aoColumns;
|
19108 |
+
|
19109 |
+
oState.ColReorder = [];
|
19110 |
+
|
19111 |
+
/* Sorting */
|
19112 |
+
if ( oState.aaSorting ) {
|
19113 |
+
// 1.10.0-
|
19114 |
+
for ( i=0 ; i<oState.aaSorting.length ; i++ ) {
|
19115 |
+
oState.aaSorting[i][0] = columns[ oState.aaSorting[i][0] ]._ColReorder_iOrigCol;
|
19116 |
+
}
|
19117 |
+
|
19118 |
+
var aSearchCopy = $.extend( true, [], oState.aoSearchCols );
|
19119 |
+
|
19120 |
+
for ( i=0, iLen=columns.length ; i<iLen ; i++ )
|
19121 |
+
{
|
19122 |
+
iOrigColumn = columns[i]._ColReorder_iOrigCol;
|
19123 |
+
|
19124 |
+
/* Column filter */
|
19125 |
+
oState.aoSearchCols[ iOrigColumn ] = aSearchCopy[i];
|
19126 |
+
|
19127 |
+
/* Visibility */
|
19128 |
+
oState.abVisCols[ iOrigColumn ] = columns[i].bVisible;
|
19129 |
+
|
19130 |
+
/* Column reordering */
|
19131 |
+
oState.ColReorder.push( iOrigColumn );
|
19132 |
+
}
|
19133 |
+
}
|
19134 |
+
else if ( oState.order ) {
|
19135 |
+
// 1.10.1+
|
19136 |
+
for ( i=0 ; i<oState.order.length ; i++ ) {
|
19137 |
+
oState.order[i][0] = columns[ oState.order[i][0] ]._ColReorder_iOrigCol;
|
19138 |
+
}
|
19139 |
+
|
19140 |
+
var stateColumnsCopy = $.extend( true, [], oState.columns );
|
19141 |
+
|
19142 |
+
for ( i=0, iLen=columns.length ; i<iLen ; i++ )
|
19143 |
+
{
|
19144 |
+
iOrigColumn = columns[i]._ColReorder_iOrigCol;
|
19145 |
+
|
19146 |
+
/* Columns */
|
19147 |
+
oState.columns[ iOrigColumn ] = stateColumnsCopy[i];
|
19148 |
+
|
19149 |
+
/* Column reordering */
|
19150 |
+
oState.ColReorder.push( iOrigColumn );
|
19151 |
+
}
|
19152 |
+
}
|
19153 |
+
},
|
19154 |
+
|
19155 |
+
|
19156 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
19157 |
+
* Mouse drop and drag
|
19158 |
+
*/
|
19159 |
+
|
19160 |
+
/**
|
19161 |
+
* Add a mouse down listener to a particluar TH element
|
19162 |
+
* @method _fnMouseListener
|
19163 |
+
* @param int i Column index
|
19164 |
+
* @param element nTh TH element clicked on
|
19165 |
+
* @returns void
|
19166 |
+
* @private
|
19167 |
+
*/
|
19168 |
+
"_fnMouseListener": function ( i, nTh )
|
19169 |
+
{
|
19170 |
+
var that = this;
|
19171 |
+
$(nTh)
|
19172 |
+
.on( 'mousedown.ColReorder', function (e) {
|
19173 |
+
that._fnMouseDown.call( that, e, nTh );
|
19174 |
+
} )
|
19175 |
+
.on( 'touchstart.ColReorder', function (e) {
|
19176 |
+
that._fnMouseDown.call( that, e, nTh );
|
19177 |
+
} );
|
19178 |
+
},
|
19179 |
+
|
19180 |
+
|
19181 |
+
/**
|
19182 |
+
* Mouse down on a TH element in the table header
|
19183 |
+
* @method _fnMouseDown
|
19184 |
+
* @param event e Mouse event
|
19185 |
+
* @param element nTh TH element to be dragged
|
19186 |
+
* @returns void
|
19187 |
+
* @private
|
19188 |
+
*/
|
19189 |
+
"_fnMouseDown": function ( e, nTh )
|
19190 |
+
{
|
19191 |
+
var that = this;
|
19192 |
+
|
19193 |
+
/* Store information about the mouse position */
|
19194 |
+
var target = $(e.target).closest('th, td');
|
19195 |
+
var offset = target.offset();
|
19196 |
+
var idx = parseInt( $(nTh).attr('data-column-index'), 10 );
|
19197 |
+
|
19198 |
+
if ( idx === undefined ) {
|
19199 |
+
return;
|
19200 |
+
}
|
19201 |
+
|
19202 |
+
this.s.mouse.startX = this._fnCursorPosition( e, 'pageX' );
|
19203 |
+
this.s.mouse.startY = this._fnCursorPosition( e, 'pageY' );
|
19204 |
+
this.s.mouse.offsetX = this._fnCursorPosition( e, 'pageX' ) - offset.left;
|
19205 |
+
this.s.mouse.offsetY = this._fnCursorPosition( e, 'pageY' ) - offset.top;
|
19206 |
+
this.s.mouse.target = this.s.dt.aoColumns[ idx ].nTh;//target[0];
|
19207 |
+
this.s.mouse.targetIndex = idx;
|
19208 |
+
this.s.mouse.fromIndex = idx;
|
19209 |
+
|
19210 |
+
this._fnRegions();
|
19211 |
+
|
19212 |
+
/* Add event handlers to the document */
|
19213 |
+
$(document)
|
19214 |
+
.on( 'mousemove.ColReorder touchmove.ColReorder', function (e) {
|
19215 |
+
that._fnMouseMove.call( that, e );
|
19216 |
+
} )
|
19217 |
+
.on( 'mouseup.ColReorder touchend.ColReorder', function (e) {
|
19218 |
+
that._fnMouseUp.call( that, e );
|
19219 |
+
} );
|
19220 |
+
},
|
19221 |
+
|
19222 |
+
|
19223 |
+
/**
|
19224 |
+
* Deal with a mouse move event while dragging a node
|
19225 |
+
* @method _fnMouseMove
|
19226 |
+
* @param event e Mouse event
|
19227 |
+
* @returns void
|
19228 |
+
* @private
|
19229 |
+
*/
|
19230 |
+
"_fnMouseMove": function ( e )
|
19231 |
+
{
|
19232 |
+
var that = this;
|
19233 |
+
|
19234 |
+
if ( this.dom.drag === null )
|
19235 |
+
{
|
19236 |
+
/* Only create the drag element if the mouse has moved a specific distance from the start
|
19237 |
+
* point - this allows the user to make small mouse movements when sorting and not have a
|
19238 |
+
* possibly confusing drag element showing up
|
19239 |
+
*/
|
19240 |
+
if ( Math.pow(
|
19241 |
+
Math.pow(this._fnCursorPosition( e, 'pageX') - this.s.mouse.startX, 2) +
|
19242 |
+
Math.pow(this._fnCursorPosition( e, 'pageY') - this.s.mouse.startY, 2), 0.5 ) < 5 )
|
19243 |
+
{
|
19244 |
+
return;
|
19245 |
+
}
|
19246 |
+
this._fnCreateDragNode();
|
19247 |
+
}
|
19248 |
+
|
19249 |
+
/* Position the element - we respect where in the element the click occured */
|
19250 |
+
this.dom.drag.css( {
|
19251 |
+
left: this._fnCursorPosition( e, 'pageX' ) - this.s.mouse.offsetX,
|
19252 |
+
top: this._fnCursorPosition( e, 'pageY' ) - this.s.mouse.offsetY
|
19253 |
+
} );
|
19254 |
+
|
19255 |
+
/* Based on the current mouse position, calculate where the insert should go */
|
19256 |
+
var bSet = false;
|
19257 |
+
var lastToIndex = this.s.mouse.toIndex;
|
19258 |
+
|
19259 |
+
for ( var i=1, iLen=this.s.aoTargets.length ; i<iLen ; i++ )
|
19260 |
+
{
|
19261 |
+
if ( this._fnCursorPosition(e, 'pageX') < this.s.aoTargets[i-1].x + ((this.s.aoTargets[i].x-this.s.aoTargets[i-1].x)/2) )
|
19262 |
+
{
|
19263 |
+
this.dom.pointer.css( 'left', this.s.aoTargets[i-1].x );
|
19264 |
+
this.s.mouse.toIndex = this.s.aoTargets[i-1].to;
|
19265 |
+
bSet = true;
|
19266 |
+
break;
|
19267 |
+
}
|
19268 |
+
}
|
19269 |
+
|
19270 |
+
// The insert element wasn't positioned in the array (less than
|
19271 |
+
// operator), so we put it at the end
|
19272 |
+
if ( !bSet )
|
19273 |
+
{
|
19274 |
+
this.dom.pointer.css( 'left', this.s.aoTargets[this.s.aoTargets.length-1].x );
|
19275 |
+
this.s.mouse.toIndex = this.s.aoTargets[this.s.aoTargets.length-1].to;
|
19276 |
+
}
|
19277 |
+
|
19278 |
+
// Perform reordering if realtime updating is on and the column has moved
|
19279 |
+
if ( this.s.init.bRealtime && lastToIndex !== this.s.mouse.toIndex ) {
|
19280 |
+
this.s.dt.oInstance.fnColReorder( this.s.mouse.fromIndex, this.s.mouse.toIndex, false );
|
19281 |
+
this.s.mouse.fromIndex = this.s.mouse.toIndex;
|
19282 |
+
this._fnRegions();
|
19283 |
+
}
|
19284 |
+
},
|
19285 |
+
|
19286 |
+
|
19287 |
+
/**
|
19288 |
+
* Finish off the mouse drag and insert the column where needed
|
19289 |
+
* @method _fnMouseUp
|
19290 |
+
* @param event e Mouse event
|
19291 |
+
* @returns void
|
19292 |
+
* @private
|
19293 |
+
*/
|
19294 |
+
"_fnMouseUp": function ( e )
|
19295 |
+
{
|
19296 |
+
var that = this;
|
19297 |
+
|
19298 |
+
$(document).off( '.ColReorder' );
|
19299 |
+
|
19300 |
+
if ( this.dom.drag !== null )
|
19301 |
+
{
|
19302 |
+
/* Remove the guide elements */
|
19303 |
+
this.dom.drag.remove();
|
19304 |
+
this.dom.pointer.remove();
|
19305 |
+
this.dom.drag = null;
|
19306 |
+
this.dom.pointer = null;
|
19307 |
+
|
19308 |
+
/* Actually do the reorder */
|
19309 |
+
this.s.dt.oInstance.fnColReorder( this.s.mouse.fromIndex, this.s.mouse.toIndex, true );
|
19310 |
+
this._fnSetColumnIndexes();
|
19311 |
+
|
19312 |
+
/* When scrolling we need to recalculate the column sizes to allow for the shift */
|
19313 |
+
if ( this.s.dt.oScroll.sX !== "" || this.s.dt.oScroll.sY !== "" )
|
19314 |
+
{
|
19315 |
+
this.s.dt.oInstance.fnAdjustColumnSizing( false );
|
19316 |
+
}
|
19317 |
+
|
19318 |
+
/* Save the state */
|
19319 |
+
this.s.dt.oInstance.oApi._fnSaveState( this.s.dt );
|
19320 |
+
|
19321 |
+
if ( this.s.reorderCallback !== null )
|
19322 |
+
{
|
19323 |
+
this.s.reorderCallback.call( this );
|
19324 |
+
}
|
19325 |
+
}
|
19326 |
+
},
|
19327 |
+
|
19328 |
+
|
19329 |
+
/**
|
19330 |
+
* Calculate a cached array with the points of the column inserts, and the
|
19331 |
+
* 'to' points
|
19332 |
+
* @method _fnRegions
|
19333 |
+
* @returns void
|
19334 |
+
* @private
|
19335 |
+
*/
|
19336 |
+
"_fnRegions": function ()
|
19337 |
+
{
|
19338 |
+
var aoColumns = this.s.dt.aoColumns;
|
19339 |
+
|
19340 |
+
this.s.aoTargets.splice( 0, this.s.aoTargets.length );
|
19341 |
+
|
19342 |
+
this.s.aoTargets.push( {
|
19343 |
+
"x": $(this.s.dt.nTable).offset().left,
|
19344 |
+
"to": 0
|
19345 |
+
} );
|
19346 |
+
|
19347 |
+
var iToPoint = 0;
|
19348 |
+
var total = this.s.aoTargets[0].x;
|
19349 |
+
|
19350 |
+
for ( var i=0, iLen=aoColumns.length ; i<iLen ; i++ )
|
19351 |
+
{
|
19352 |
+
/* For the column / header in question, we want it's position to remain the same if the
|
19353 |
+
* position is just to it's immediate left or right, so we only increment the counter for
|
19354 |
+
* other columns
|
19355 |
+
*/
|
19356 |
+
if ( i != this.s.mouse.fromIndex )
|
19357 |
+
{
|
19358 |
+
iToPoint++;
|
19359 |
+
}
|
19360 |
+
|
19361 |
+
if ( aoColumns[i].bVisible && aoColumns[i].nTh.style.display !=='none' )
|
19362 |
+
{
|
19363 |
+
total += $(aoColumns[i].nTh).outerWidth();
|
19364 |
+
|
19365 |
+
this.s.aoTargets.push( {
|
19366 |
+
"x": total,
|
19367 |
+
"to": iToPoint
|
19368 |
+
} );
|
19369 |
+
}
|
19370 |
+
}
|
19371 |
+
|
19372 |
+
/* Disallow columns for being reordered by drag and drop, counting right to left */
|
19373 |
+
if ( this.s.fixedRight !== 0 )
|
19374 |
+
{
|
19375 |
+
this.s.aoTargets.splice( this.s.aoTargets.length - this.s.fixedRight );
|
19376 |
+
}
|
19377 |
+
|
19378 |
+
/* Disallow columns for being reordered by drag and drop, counting left to right */
|
19379 |
+
if ( this.s.fixed !== 0 )
|
19380 |
+
{
|
19381 |
+
this.s.aoTargets.splice( 0, this.s.fixed );
|
19382 |
+
}
|
19383 |
+
},
|
19384 |
+
|
19385 |
+
|
19386 |
+
/**
|
19387 |
+
* Copy the TH element that is being drags so the user has the idea that they are actually
|
19388 |
+
* moving it around the page.
|
19389 |
+
* @method _fnCreateDragNode
|
19390 |
+
* @returns void
|
19391 |
+
* @private
|
19392 |
+
*/
|
19393 |
+
"_fnCreateDragNode": function ()
|
19394 |
+
{
|
19395 |
+
var scrolling = this.s.dt.oScroll.sX !== "" || this.s.dt.oScroll.sY !== "";
|
19396 |
+
|
19397 |
+
var origCell = this.s.dt.aoColumns[ this.s.mouse.targetIndex ].nTh;
|
19398 |
+
var origTr = origCell.parentNode;
|
19399 |
+
var origThead = origTr.parentNode;
|
19400 |
+
var origTable = origThead.parentNode;
|
19401 |
+
var cloneCell = $(origCell).clone();
|
19402 |
+
|
19403 |
+
// This is a slightly odd combination of jQuery and DOM, but it is the
|
19404 |
+
// fastest and least resource intensive way I could think of cloning
|
19405 |
+
// the table with just a single header cell in it.
|
19406 |
+
this.dom.drag = $(origTable.cloneNode(false))
|
19407 |
+
.addClass( 'DTCR_clonedTable' )
|
19408 |
+
.append(
|
19409 |
+
$(origThead.cloneNode(false)).append(
|
19410 |
+
$(origTr.cloneNode(false)).append(
|
19411 |
+
cloneCell[0]
|
19412 |
+
)
|
19413 |
+
)
|
19414 |
+
)
|
19415 |
+
.css( {
|
19416 |
+
position: 'absolute',
|
19417 |
+
top: 0,
|
19418 |
+
left: 0,
|
19419 |
+
width: $(origCell).outerWidth(),
|
19420 |
+
height: $(origCell).outerHeight()
|
19421 |
+
} )
|
19422 |
+
.appendTo( 'body' );
|
19423 |
+
|
19424 |
+
this.dom.pointer = $('<div></div>')
|
19425 |
+
.addClass( 'DTCR_pointer' )
|
19426 |
+
.css( {
|
19427 |
+
position: 'absolute',
|
19428 |
+
top: scrolling ?
|
19429 |
+
$('div.dataTables_scroll', this.s.dt.nTableWrapper).offset().top :
|
19430 |
+
$(this.s.dt.nTable).offset().top,
|
19431 |
+
height : scrolling ?
|
19432 |
+
$('div.dataTables_scroll', this.s.dt.nTableWrapper).height() :
|
19433 |
+
$(this.s.dt.nTable).height()
|
19434 |
+
} )
|
19435 |
+
.appendTo( 'body' );
|
19436 |
+
},
|
19437 |
+
|
19438 |
+
|
19439 |
+
/**
|
19440 |
+
* Add a data attribute to the column headers, so we know the index of
|
19441 |
+
* the row to be reordered. This allows fast detection of the index, and
|
19442 |
+
* for this plug-in to work with FixedHeader which clones the nodes.
|
19443 |
+
* @private
|
19444 |
+
*/
|
19445 |
+
"_fnSetColumnIndexes": function ()
|
19446 |
+
{
|
19447 |
+
$.each( this.s.dt.aoColumns, function (i, column) {
|
19448 |
+
$(column.nTh).attr('data-column-index', i);
|
19449 |
+
} );
|
19450 |
+
},
|
19451 |
+
|
19452 |
+
|
19453 |
+
/**
|
19454 |
+
* Get cursor position regardless of mouse or touch input
|
19455 |
+
* @param {Event} e jQuery Event
|
19456 |
+
* @param {string} prop Property to get
|
19457 |
+
* @return {number} Value
|
19458 |
+
*/
|
19459 |
+
_fnCursorPosition: function ( e, prop ) {
|
19460 |
+
if ( e.type.indexOf('touch') !== -1 ) {
|
19461 |
+
return e.originalEvent.touches[0][ prop ];
|
19462 |
+
}
|
19463 |
+
return e[ prop ];
|
19464 |
+
}
|
19465 |
+
} );
|
19466 |
+
|
19467 |
+
|
19468 |
+
|
19469 |
+
|
19470 |
+
|
19471 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
19472 |
+
* Static parameters
|
19473 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
19474 |
+
|
19475 |
+
|
19476 |
+
/**
|
19477 |
+
* ColReorder default settings for initialisation
|
19478 |
+
* @namespace
|
19479 |
+
* @static
|
19480 |
+
*/
|
19481 |
+
ColReorder.defaults = {
|
19482 |
+
/**
|
19483 |
+
* Predefined ordering for the columns that will be applied automatically
|
19484 |
+
* on initialisation. If not specified then the order that the columns are
|
19485 |
+
* found to be in the HTML is the order used.
|
19486 |
+
* @type array
|
19487 |
+
* @default null
|
19488 |
+
* @static
|
19489 |
+
*/
|
19490 |
+
aiOrder: null,
|
19491 |
+
|
19492 |
+
/**
|
19493 |
+
* Redraw the table's column ordering as the end user draws the column
|
19494 |
+
* (`true`) or wait until the mouse is released (`false` - default). Note
|
19495 |
+
* that this will perform a redraw on each reordering, which involves an
|
19496 |
+
* Ajax request each time if you are using server-side processing in
|
19497 |
+
* DataTables.
|
19498 |
+
* @type boolean
|
19499 |
+
* @default false
|
19500 |
+
* @static
|
19501 |
+
*/
|
19502 |
+
bRealtime: true,
|
19503 |
+
|
19504 |
+
/**
|
19505 |
+
* Indicate how many columns should be fixed in position (counting from the
|
19506 |
+
* left). This will typically be 1 if used, but can be as high as you like.
|
19507 |
+
* @type int
|
19508 |
+
* @default 0
|
19509 |
+
* @static
|
19510 |
+
*/
|
19511 |
+
iFixedColumnsLeft: 0,
|
19512 |
+
|
19513 |
+
/**
|
19514 |
+
* As `iFixedColumnsRight` but counting from the right.
|
19515 |
+
* @type int
|
19516 |
+
* @default 0
|
19517 |
+
* @static
|
19518 |
+
*/
|
19519 |
+
iFixedColumnsRight: 0,
|
19520 |
+
|
19521 |
+
/**
|
19522 |
+
* Callback function that is fired when columns are reordered. The `column-
|
19523 |
+
* reorder` event is preferred over this callback
|
19524 |
+
* @type function():void
|
19525 |
+
* @default null
|
19526 |
+
* @static
|
19527 |
+
*/
|
19528 |
+
fnReorderCallback: null
|
19529 |
+
};
|
19530 |
+
|
19531 |
+
|
19532 |
+
|
19533 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
19534 |
+
* Constants
|
19535 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
19536 |
+
|
19537 |
+
/**
|
19538 |
+
* ColReorder version
|
19539 |
+
* @constant version
|
19540 |
+
* @type String
|
19541 |
+
* @default As code
|
19542 |
+
*/
|
19543 |
+
ColReorder.version = "1.4.1";
|
19544 |
+
|
19545 |
+
|
19546 |
+
|
19547 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
19548 |
+
* DataTables interfaces
|
19549 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
19550 |
+
|
19551 |
+
// Expose
|
19552 |
+
$.fn.dataTable.ColReorder = ColReorder;
|
19553 |
+
$.fn.DataTable.ColReorder = ColReorder;
|
19554 |
+
|
19555 |
+
|
19556 |
+
// Register a new feature with DataTables
|
19557 |
+
if ( typeof $.fn.dataTable == "function" &&
|
19558 |
+
typeof $.fn.dataTableExt.fnVersionCheck == "function" &&
|
19559 |
+
$.fn.dataTableExt.fnVersionCheck('1.10.8') )
|
19560 |
+
{
|
19561 |
+
$.fn.dataTableExt.aoFeatures.push( {
|
19562 |
+
"fnInit": function( settings ) {
|
19563 |
+
var table = settings.oInstance;
|
19564 |
+
|
19565 |
+
if ( ! settings._colReorder ) {
|
19566 |
+
var dtInit = settings.oInit;
|
19567 |
+
var opts = dtInit.colReorder || dtInit.oColReorder || {};
|
19568 |
+
|
19569 |
+
new ColReorder( settings, opts );
|
19570 |
+
}
|
19571 |
+
else {
|
19572 |
+
table.oApi._fnLog( settings, 1, "ColReorder attempted to initialise twice. Ignoring second" );
|
19573 |
+
}
|
19574 |
+
|
19575 |
+
return null; /* No node for DataTables to insert */
|
19576 |
+
},
|
19577 |
+
"cFeature": "R",
|
19578 |
+
"sFeature": "ColReorder"
|
19579 |
+
} );
|
19580 |
+
}
|
19581 |
+
else {
|
19582 |
+
alert( "Warning: ColReorder requires DataTables 1.10.8 or greater - www.datatables.net/download");
|
19583 |
+
}
|
19584 |
+
|
19585 |
+
|
19586 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
19587 |
+
// events so we can automatically initialise
|
19588 |
+
$(document).on( 'preInit.dt.colReorder', function (e, settings) {
|
19589 |
+
if ( e.namespace !== 'dt' ) {
|
19590 |
+
return;
|
19591 |
+
}
|
19592 |
+
|
19593 |
+
var init = settings.oInit.colReorder;
|
19594 |
+
var defaults = DataTable.defaults.colReorder;
|
19595 |
+
|
19596 |
+
if ( init || defaults ) {
|
19597 |
+
var opts = $.extend( {}, init, defaults );
|
19598 |
+
|
19599 |
+
if ( init !== false ) {
|
19600 |
+
new ColReorder( settings, opts );
|
19601 |
+
}
|
19602 |
+
}
|
19603 |
+
} );
|
19604 |
+
|
19605 |
+
|
19606 |
+
// API augmentation
|
19607 |
+
$.fn.dataTable.Api.register( 'colReorder.reset()', function () {
|
19608 |
+
return this.iterator( 'table', function ( ctx ) {
|
19609 |
+
ctx._colReorder.fnReset();
|
19610 |
+
} );
|
19611 |
+
} );
|
19612 |
+
|
19613 |
+
$.fn.dataTable.Api.register( 'colReorder.order()', function ( set, original ) {
|
19614 |
+
if ( set ) {
|
19615 |
+
return this.iterator( 'table', function ( ctx ) {
|
19616 |
+
ctx._colReorder.fnOrder( set, original );
|
19617 |
+
} );
|
19618 |
+
}
|
19619 |
+
|
19620 |
+
return this.context.length ?
|
19621 |
+
this.context[0]._colReorder.fnOrder() :
|
19622 |
+
null;
|
19623 |
+
} );
|
19624 |
+
|
19625 |
+
$.fn.dataTable.Api.register( 'colReorder.transpose()', function ( idx, dir ) {
|
19626 |
+
return this.context.length && this.context[0]._colReorder ?
|
19627 |
+
this.context[0]._colReorder.fnTranspose( idx, dir ) :
|
19628 |
+
idx;
|
19629 |
+
} );
|
19630 |
+
|
19631 |
+
$.fn.dataTable.Api.register( 'colReorder.move()', function( from, to, drop, invalidateRows ) {
|
19632 |
+
if (this.context.length) {
|
19633 |
+
this.context[0]._colReorder.s.dt.oInstance.fnColReorder( from, to, drop, invalidateRows );
|
19634 |
+
}
|
19635 |
+
return this;
|
19636 |
+
} );
|
19637 |
+
|
19638 |
+
|
19639 |
+
return ColReorder;
|
19640 |
+
}));
|
19641 |
+
|
19642 |
+
|
19643 |
+
/*! FixedColumns 3.2.4
|
19644 |
+
* ©2010-2017 SpryMedia Ltd - datatables.net/license
|
19645 |
+
*/
|
19646 |
+
|
19647 |
+
/**
|
19648 |
+
* @summary FixedColumns
|
19649 |
+
* @description Freeze columns in place on a scrolling DataTable
|
19650 |
+
* @version 3.2.4
|
19651 |
+
* @file dataTables.fixedColumns.js
|
19652 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
19653 |
+
* @contact www.sprymedia.co.uk/contact
|
19654 |
+
* @copyright Copyright 2010-2017 SpryMedia Ltd.
|
19655 |
+
*
|
19656 |
+
* This source file is free software, available under the following license:
|
19657 |
+
* MIT license - http://datatables.net/license/mit
|
19658 |
+
*
|
19659 |
+
* This source file is distributed in the hope that it will be useful, but
|
19660 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
19661 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
19662 |
+
*
|
19663 |
+
* For details please refer to: http://www.datatables.net
|
19664 |
+
*/
|
19665 |
+
(function( factory ){
|
19666 |
+
if ( typeof define === 'function' && define.amd ) {
|
19667 |
+
// AMD
|
19668 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
19669 |
+
return factory( $, window, document );
|
19670 |
+
} );
|
19671 |
+
}
|
19672 |
+
else if ( typeof exports === 'object' ) {
|
19673 |
+
// CommonJS
|
19674 |
+
module.exports = function (root, $) {
|
19675 |
+
if ( ! root ) {
|
19676 |
+
root = window;
|
19677 |
+
}
|
19678 |
+
|
19679 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
19680 |
+
$ = require('datatables.net')(root, $).$;
|
19681 |
+
}
|
19682 |
+
|
19683 |
+
return factory( $, root, root.document );
|
19684 |
+
};
|
19685 |
+
}
|
19686 |
+
else {
|
19687 |
+
// Browser
|
19688 |
+
factory( jQuery, window, document );
|
19689 |
+
}
|
19690 |
+
}(function( $, window, document, undefined ) {
|
19691 |
+
'use strict';
|
19692 |
+
var DataTable = $.fn.dataTable;
|
19693 |
+
var _firefoxScroll;
|
19694 |
+
|
19695 |
+
/**
|
19696 |
+
* When making use of DataTables' x-axis scrolling feature, you may wish to
|
19697 |
+
* fix the left most column in place. This plug-in for DataTables provides
|
19698 |
+
* exactly this option (note for non-scrolling tables, please use the
|
19699 |
+
* FixedHeader plug-in, which can fix headers and footers). Key
|
19700 |
+
* features include:
|
19701 |
+
*
|
19702 |
+
* * Freezes the left or right most columns to the side of the table
|
19703 |
+
* * Option to freeze two or more columns
|
19704 |
+
* * Full integration with DataTables' scrolling options
|
19705 |
+
* * Speed - FixedColumns is fast in its operation
|
19706 |
+
*
|
19707 |
+
* @class
|
19708 |
+
* @constructor
|
19709 |
+
* @global
|
19710 |
+
* @param {object} dt DataTables instance. With DataTables 1.10 this can also
|
19711 |
+
* be a jQuery collection, a jQuery selector, DataTables API instance or
|
19712 |
+
* settings object.
|
19713 |
+
* @param {object} [init={}] Configuration object for FixedColumns. Options are
|
19714 |
+
* defined by {@link FixedColumns.defaults}
|
19715 |
+
*
|
19716 |
+
* @requires jQuery 1.7+
|
19717 |
+
* @requires DataTables 1.8.0+
|
19718 |
+
*
|
19719 |
+
* @example
|
19720 |
+
* var table = $('#example').dataTable( {
|
19721 |
+
* "scrollX": "100%"
|
19722 |
+
* } );
|
19723 |
+
* new $.fn.dataTable.fixedColumns( table );
|
19724 |
+
*/
|
19725 |
+
var FixedColumns = function ( dt, init ) {
|
19726 |
+
var that = this;
|
19727 |
+
|
19728 |
+
/* Sanity check - you just know it will happen */
|
19729 |
+
if ( ! ( this instanceof FixedColumns ) ) {
|
19730 |
+
alert( "FixedColumns warning: FixedColumns must be initialised with the 'new' keyword." );
|
19731 |
+
return;
|
19732 |
+
}
|
19733 |
+
|
19734 |
+
if ( init === undefined || init === true ) {
|
19735 |
+
init = {};
|
19736 |
+
}
|
19737 |
+
|
19738 |
+
// Use the DataTables Hungarian notation mapping method, if it exists to
|
19739 |
+
// provide forwards compatibility for camel case variables
|
19740 |
+
var camelToHungarian = $.fn.dataTable.camelToHungarian;
|
19741 |
+
if ( camelToHungarian ) {
|
19742 |
+
camelToHungarian( FixedColumns.defaults, FixedColumns.defaults, true );
|
19743 |
+
camelToHungarian( FixedColumns.defaults, init );
|
19744 |
+
}
|
19745 |
+
|
19746 |
+
// v1.10 allows the settings object to be got form a number of sources
|
19747 |
+
var dtSettings = new $.fn.dataTable.Api( dt ).settings()[0];
|
19748 |
+
|
19749 |
+
/**
|
19750 |
+
* Settings object which contains customisable information for FixedColumns instance
|
19751 |
+
* @namespace
|
19752 |
+
* @extends FixedColumns.defaults
|
19753 |
+
* @private
|
19754 |
+
*/
|
19755 |
+
this.s = {
|
19756 |
+
/**
|
19757 |
+
* DataTables settings objects
|
19758 |
+
* @type object
|
19759 |
+
* @default Obtained from DataTables instance
|
19760 |
+
*/
|
19761 |
+
"dt": dtSettings,
|
19762 |
+
|
19763 |
+
/**
|
19764 |
+
* Number of columns in the DataTable - stored for quick access
|
19765 |
+
* @type int
|
19766 |
+
* @default Obtained from DataTables instance
|
19767 |
+
*/
|
19768 |
+
"iTableColumns": dtSettings.aoColumns.length,
|
19769 |
+
|
19770 |
+
/**
|
19771 |
+
* Original outer widths of the columns as rendered by DataTables - used to calculate
|
19772 |
+
* the FixedColumns grid bounding box
|
19773 |
+
* @type array.<int>
|
19774 |
+
* @default []
|
19775 |
+
*/
|
19776 |
+
"aiOuterWidths": [],
|
19777 |
+
|
19778 |
+
/**
|
19779 |
+
* Original inner widths of the columns as rendered by DataTables - used to apply widths
|
19780 |
+
* to the columns
|
19781 |
+
* @type array.<int>
|
19782 |
+
* @default []
|
19783 |
+
*/
|
19784 |
+
"aiInnerWidths": [],
|
19785 |
+
|
19786 |
+
|
19787 |
+
/**
|
19788 |
+
* Is the document layout right-to-left
|
19789 |
+
* @type boolean
|
19790 |
+
*/
|
19791 |
+
rtl: $(dtSettings.nTable).css('direction') === 'rtl'
|
19792 |
+
};
|
19793 |
+
|
19794 |
+
|
19795 |
+
/**
|
19796 |
+
* DOM elements used by the class instance
|
19797 |
+
* @namespace
|
19798 |
+
* @private
|
19799 |
+
*
|
19800 |
+
*/
|
19801 |
+
this.dom = {
|
19802 |
+
/**
|
19803 |
+
* DataTables scrolling element
|
19804 |
+
* @type node
|
19805 |
+
* @default null
|
19806 |
+
*/
|
19807 |
+
"scroller": null,
|
19808 |
+
|
19809 |
+
/**
|
19810 |
+
* DataTables header table
|
19811 |
+
* @type node
|
19812 |
+
* @default null
|
19813 |
+
*/
|
19814 |
+
"header": null,
|
19815 |
+
|
19816 |
+
/**
|
19817 |
+
* DataTables body table
|
19818 |
+
* @type node
|
19819 |
+
* @default null
|
19820 |
+
*/
|
19821 |
+
"body": null,
|
19822 |
+
|
19823 |
+
/**
|
19824 |
+
* DataTables footer table
|
19825 |
+
* @type node
|
19826 |
+
* @default null
|
19827 |
+
*/
|
19828 |
+
"footer": null,
|
19829 |
+
|
19830 |
+
/**
|
19831 |
+
* Display grid elements
|
19832 |
+
* @namespace
|
19833 |
+
*/
|
19834 |
+
"grid": {
|
19835 |
+
/**
|
19836 |
+
* Grid wrapper. This is the container element for the 3x3 grid
|
19837 |
+
* @type node
|
19838 |
+
* @default null
|
19839 |
+
*/
|
19840 |
+
"wrapper": null,
|
19841 |
+
|
19842 |
+
/**
|
19843 |
+
* DataTables scrolling element. This element is the DataTables
|
19844 |
+
* component in the display grid (making up the main table - i.e.
|
19845 |
+
* not the fixed columns).
|
19846 |
+
* @type node
|
19847 |
+
* @default null
|
19848 |
+
*/
|
19849 |
+
"dt": null,
|
19850 |
+
|
19851 |
+
/**
|
19852 |
+
* Left fixed column grid components
|
19853 |
+
* @namespace
|
19854 |
+
*/
|
19855 |
+
"left": {
|
19856 |
+
"wrapper": null,
|
19857 |
+
"head": null,
|
19858 |
+
"body": null,
|
19859 |
+
"foot": null
|
19860 |
+
},
|
19861 |
+
|
19862 |
+
/**
|
19863 |
+
* Right fixed column grid components
|
19864 |
+
* @namespace
|
19865 |
+
*/
|
19866 |
+
"right": {
|
19867 |
+
"wrapper": null,
|
19868 |
+
"head": null,
|
19869 |
+
"body": null,
|
19870 |
+
"foot": null
|
19871 |
+
}
|
19872 |
+
},
|
19873 |
+
|
19874 |
+
/**
|
19875 |
+
* Cloned table nodes
|
19876 |
+
* @namespace
|
19877 |
+
*/
|
19878 |
+
"clone": {
|
19879 |
+
/**
|
19880 |
+
* Left column cloned table nodes
|
19881 |
+
* @namespace
|
19882 |
+
*/
|
19883 |
+
"left": {
|
19884 |
+
/**
|
19885 |
+
* Cloned header table
|
19886 |
+
* @type node
|
19887 |
+
* @default null
|
19888 |
+
*/
|
19889 |
+
"header": null,
|
19890 |
+
|
19891 |
+
/**
|
19892 |
+
* Cloned body table
|
19893 |
+
* @type node
|
19894 |
+
* @default null
|
19895 |
+
*/
|
19896 |
+
"body": null,
|
19897 |
+
|
19898 |
+
/**
|
19899 |
+
* Cloned footer table
|
19900 |
+
* @type node
|
19901 |
+
* @default null
|
19902 |
+
*/
|
19903 |
+
"footer": null
|
19904 |
+
},
|
19905 |
+
|
19906 |
+
/**
|
19907 |
+
* Right column cloned table nodes
|
19908 |
+
* @namespace
|
19909 |
+
*/
|
19910 |
+
"right": {
|
19911 |
+
/**
|
19912 |
+
* Cloned header table
|
19913 |
+
* @type node
|
19914 |
+
* @default null
|
19915 |
+
*/
|
19916 |
+
"header": null,
|
19917 |
+
|
19918 |
+
/**
|
19919 |
+
* Cloned body table
|
19920 |
+
* @type node
|
19921 |
+
* @default null
|
19922 |
+
*/
|
19923 |
+
"body": null,
|
19924 |
+
|
19925 |
+
/**
|
19926 |
+
* Cloned footer table
|
19927 |
+
* @type node
|
19928 |
+
* @default null
|
19929 |
+
*/
|
19930 |
+
"footer": null
|
19931 |
+
}
|
19932 |
+
}
|
19933 |
+
};
|
19934 |
+
|
19935 |
+
if ( dtSettings._oFixedColumns ) {
|
19936 |
+
throw 'FixedColumns already initialised on this table';
|
19937 |
+
}
|
19938 |
+
|
19939 |
+
/* Attach the instance to the DataTables instance so it can be accessed easily */
|
19940 |
+
dtSettings._oFixedColumns = this;
|
19941 |
+
|
19942 |
+
/* Let's do it */
|
19943 |
+
if ( ! dtSettings._bInitComplete )
|
19944 |
+
{
|
19945 |
+
dtSettings.oApi._fnCallbackReg( dtSettings, 'aoInitComplete', function () {
|
19946 |
+
that._fnConstruct( init );
|
19947 |
+
}, 'FixedColumns' );
|
19948 |
+
}
|
19949 |
+
else
|
19950 |
+
{
|
19951 |
+
this._fnConstruct( init );
|
19952 |
+
}
|
19953 |
+
};
|
19954 |
+
|
19955 |
+
|
19956 |
+
|
19957 |
+
$.extend( FixedColumns.prototype , {
|
19958 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
19959 |
+
* Public methods
|
19960 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
19961 |
+
|
19962 |
+
/**
|
19963 |
+
* Update the fixed columns - including headers and footers. Note that FixedColumns will
|
19964 |
+
* automatically update the display whenever the host DataTable redraws.
|
19965 |
+
* @returns {void}
|
19966 |
+
* @example
|
19967 |
+
* var table = $('#example').dataTable( {
|
19968 |
+
* "scrollX": "100%"
|
19969 |
+
* } );
|
19970 |
+
* var fc = new $.fn.dataTable.fixedColumns( table );
|
19971 |
+
*
|
19972 |
+
* // at some later point when the table has been manipulated....
|
19973 |
+
* fc.fnUpdate();
|
19974 |
+
*/
|
19975 |
+
"fnUpdate": function ()
|
19976 |
+
{
|
19977 |
+
this._fnDraw( true );
|
19978 |
+
},
|
19979 |
+
|
19980 |
+
|
19981 |
+
/**
|
19982 |
+
* Recalculate the resizes of the 3x3 grid that FixedColumns uses for display of the table.
|
19983 |
+
* This is useful if you update the width of the table container. Note that FixedColumns will
|
19984 |
+
* perform this function automatically when the window.resize event is fired.
|
19985 |
+
* @returns {void}
|
19986 |
+
* @example
|
19987 |
+
* var table = $('#example').dataTable( {
|
19988 |
+
* "scrollX": "100%"
|
19989 |
+
* } );
|
19990 |
+
* var fc = new $.fn.dataTable.fixedColumns( table );
|
19991 |
+
*
|
19992 |
+
* // Resize the table container and then have FixedColumns adjust its layout....
|
19993 |
+
* $('#content').width( 1200 );
|
19994 |
+
* fc.fnRedrawLayout();
|
19995 |
+
*/
|
19996 |
+
"fnRedrawLayout": function ()
|
19997 |
+
{
|
19998 |
+
this._fnColCalc();
|
19999 |
+
this._fnGridLayout();
|
20000 |
+
this.fnUpdate();
|
20001 |
+
},
|
20002 |
+
|
20003 |
+
|
20004 |
+
/**
|
20005 |
+
* Mark a row such that it's height should be recalculated when using 'semiauto' row
|
20006 |
+
* height matching. This function will have no effect when 'none' or 'auto' row height
|
20007 |
+
* matching is used.
|
20008 |
+
* @param {Node} nTr TR element that should have it's height recalculated
|
20009 |
+
* @returns {void}
|
20010 |
+
* @example
|
20011 |
+
* var table = $('#example').dataTable( {
|
20012 |
+
* "scrollX": "100%"
|
20013 |
+
* } );
|
20014 |
+
* var fc = new $.fn.dataTable.fixedColumns( table );
|
20015 |
+
*
|
20016 |
+
* // manipulate the table - mark the row as needing an update then update the table
|
20017 |
+
* // this allows the redraw performed by DataTables fnUpdate to recalculate the row
|
20018 |
+
* // height
|
20019 |
+
* fc.fnRecalculateHeight();
|
20020 |
+
* table.fnUpdate( $('#example tbody tr:eq(0)')[0], ["insert date", 1, 2, 3 ... ]);
|
20021 |
+
*/
|
20022 |
+
"fnRecalculateHeight": function ( nTr )
|
20023 |
+
{
|
20024 |
+
delete nTr._DTTC_iHeight;
|
20025 |
+
nTr.style.height = 'auto';
|
20026 |
+
},
|
20027 |
+
|
20028 |
+
|
20029 |
+
/**
|
20030 |
+
* Set the height of a given row - provides cross browser compatibility
|
20031 |
+
* @param {Node} nTarget TR element that should have it's height recalculated
|
20032 |
+
* @param {int} iHeight Height in pixels to set
|
20033 |
+
* @returns {void}
|
20034 |
+
* @example
|
20035 |
+
* var table = $('#example').dataTable( {
|
20036 |
+
* "scrollX": "100%"
|
20037 |
+
* } );
|
20038 |
+
* var fc = new $.fn.dataTable.fixedColumns( table );
|
20039 |
+
*
|
20040 |
+
* // You may want to do this after manipulating a row in the fixed column
|
20041 |
+
* fc.fnSetRowHeight( $('#example tbody tr:eq(0)')[0], 50 );
|
20042 |
+
*/
|
20043 |
+
"fnSetRowHeight": function ( nTarget, iHeight )
|
20044 |
+
{
|
20045 |
+
nTarget.style.height = iHeight+"px";
|
20046 |
+
},
|
20047 |
+
|
20048 |
+
|
20049 |
+
/**
|
20050 |
+
* Get data index information about a row or cell in the table body.
|
20051 |
+
* This function is functionally identical to fnGetPosition in DataTables,
|
20052 |
+
* taking the same parameter (TH, TD or TR node) and returning exactly the
|
20053 |
+
* the same information (data index information). THe difference between
|
20054 |
+
* the two is that this method takes into account the fixed columns in the
|
20055 |
+
* table, so you can pass in nodes from the master table, or the cloned
|
20056 |
+
* tables and get the index position for the data in the main table.
|
20057 |
+
* @param {node} node TR, TH or TD element to get the information about
|
20058 |
+
* @returns {int} If nNode is given as a TR, then a single index is
|
20059 |
+
* returned, or if given as a cell, an array of [row index, column index
|
20060 |
+
* (visible), column index (all)] is given.
|
20061 |
+
*/
|
20062 |
+
"fnGetPosition": function ( node )
|
20063 |
+
{
|
20064 |
+
var idx;
|
20065 |
+
var inst = this.s.dt.oInstance;
|
20066 |
+
|
20067 |
+
if ( ! $(node).parents('.DTFC_Cloned').length )
|
20068 |
+
{
|
20069 |
+
// Not in a cloned table
|
20070 |
+
return inst.fnGetPosition( node );
|
20071 |
+
}
|
20072 |
+
else
|
20073 |
+
{
|
20074 |
+
// Its in the cloned table, so need to look up position
|
20075 |
+
if ( node.nodeName.toLowerCase() === 'tr' ) {
|
20076 |
+
idx = $(node).index();
|
20077 |
+
return inst.fnGetPosition( $('tr', this.s.dt.nTBody)[ idx ] );
|
20078 |
+
}
|
20079 |
+
else
|
20080 |
+
{
|
20081 |
+
var colIdx = $(node).index();
|
20082 |
+
idx = $(node.parentNode).index();
|
20083 |
+
var row = inst.fnGetPosition( $('tr', this.s.dt.nTBody)[ idx ] );
|
20084 |
+
|
20085 |
+
return [
|
20086 |
+
row,
|
20087 |
+
colIdx,
|
20088 |
+
inst.oApi._fnVisibleToColumnIndex( this.s.dt, colIdx )
|
20089 |
+
];
|
20090 |
+
}
|
20091 |
+
}
|
20092 |
+
},
|
20093 |
+
|
20094 |
+
|
20095 |
+
|
20096 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
20097 |
+
* Private methods (they are of course public in JS, but recommended as private)
|
20098 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
20099 |
+
|
20100 |
+
/**
|
20101 |
+
* Initialisation for FixedColumns
|
20102 |
+
* @param {Object} oInit User settings for initialisation
|
20103 |
+
* @returns {void}
|
20104 |
+
* @private
|
20105 |
+
*/
|
20106 |
+
"_fnConstruct": function ( oInit )
|
20107 |
+
{
|
20108 |
+
var i, iLen, iWidth,
|
20109 |
+
that = this;
|
20110 |
+
|
20111 |
+
/* Sanity checking */
|
20112 |
+
if ( typeof this.s.dt.oInstance.fnVersionCheck != 'function' ||
|
20113 |
+
this.s.dt.oInstance.fnVersionCheck( '1.8.0' ) !== true )
|
20114 |
+
{
|
20115 |
+
alert( "FixedColumns "+FixedColumns.VERSION+" required DataTables 1.8.0 or later. "+
|
20116 |
+
"Please upgrade your DataTables installation" );
|
20117 |
+
return;
|
20118 |
+
}
|
20119 |
+
|
20120 |
+
if ( this.s.dt.oScroll.sX === "" )
|
20121 |
+
{
|
20122 |
+
this.s.dt.oInstance.oApi._fnLog( this.s.dt, 1, "FixedColumns is not needed (no "+
|
20123 |
+
"x-scrolling in DataTables enabled), so no action will be taken. Use 'FixedHeader' for "+
|
20124 |
+
"column fixing when scrolling is not enabled" );
|
20125 |
+
return;
|
20126 |
+
}
|
20127 |
+
|
20128 |
+
/* Apply the settings from the user / defaults */
|
20129 |
+
this.s = $.extend( true, this.s, FixedColumns.defaults, oInit );
|
20130 |
+
|
20131 |
+
/* Set up the DOM as we need it and cache nodes */
|
20132 |
+
var classes = this.s.dt.oClasses;
|
20133 |
+
this.dom.grid.dt = $(this.s.dt.nTable).parents('div.'+classes.sScrollWrapper)[0];
|
20134 |
+
this.dom.scroller = $('div.'+classes.sScrollBody, this.dom.grid.dt )[0];
|
20135 |
+
|
20136 |
+
/* Set up the DOM that we want for the fixed column layout grid */
|
20137 |
+
this._fnColCalc();
|
20138 |
+
this._fnGridSetup();
|
20139 |
+
|
20140 |
+
/* Event handlers */
|
20141 |
+
var mouseController;
|
20142 |
+
var mouseDown = false;
|
20143 |
+
|
20144 |
+
// When the mouse is down (drag scroll) the mouse controller cannot
|
20145 |
+
// change, as the browser keeps the original element as the scrolling one
|
20146 |
+
$(this.s.dt.nTableWrapper).on( 'mousedown.DTFC', function (e) {
|
20147 |
+
if ( e.button === 0 ) {
|
20148 |
+
mouseDown = true;
|
20149 |
+
|
20150 |
+
$(document).one( 'mouseup', function () {
|
20151 |
+
mouseDown = false;
|
20152 |
+
} );
|
20153 |
+
}
|
20154 |
+
} );
|
20155 |
+
|
20156 |
+
// When the body is scrolled - scroll the left and right columns
|
20157 |
+
$(this.dom.scroller)
|
20158 |
+
.on( 'mouseover.DTFC touchstart.DTFC', function () {
|
20159 |
+
if ( ! mouseDown ) {
|
20160 |
+
mouseController = 'main';
|
20161 |
+
}
|
20162 |
+
} )
|
20163 |
+
.on( 'scroll.DTFC', function (e) {
|
20164 |
+
if ( ! mouseController && e.originalEvent ) {
|
20165 |
+
mouseController = 'main';
|
20166 |
+
}
|
20167 |
+
|
20168 |
+
if ( mouseController === 'main' ) {
|
20169 |
+
if ( that.s.iLeftColumns > 0 ) {
|
20170 |
+
that.dom.grid.left.liner.scrollTop = that.dom.scroller.scrollTop;
|
20171 |
+
}
|
20172 |
+
if ( that.s.iRightColumns > 0 ) {
|
20173 |
+
that.dom.grid.right.liner.scrollTop = that.dom.scroller.scrollTop;
|
20174 |
+
}
|
20175 |
+
}
|
20176 |
+
} );
|
20177 |
+
|
20178 |
+
var wheelType = 'onwheel' in document.createElement('div') ?
|
20179 |
+
'wheel.DTFC' :
|
20180 |
+
'mousewheel.DTFC';
|
20181 |
+
|
20182 |
+
if ( that.s.iLeftColumns > 0 ) {
|
20183 |
+
// When scrolling the left column, scroll the body and right column
|
20184 |
+
$(that.dom.grid.left.liner)
|
20185 |
+
.on( 'mouseover.DTFC touchstart.DTFC', function () {
|
20186 |
+
if ( ! mouseDown ) {
|
20187 |
+
mouseController = 'left';
|
20188 |
+
}
|
20189 |
+
} )
|
20190 |
+
.on( 'scroll.DTFC', function ( e ) {
|
20191 |
+
if ( ! mouseController && e.originalEvent ) {
|
20192 |
+
mouseController = 'left';
|
20193 |
+
}
|
20194 |
+
|
20195 |
+
if ( mouseController === 'left' ) {
|
20196 |
+
that.dom.scroller.scrollTop = that.dom.grid.left.liner.scrollTop;
|
20197 |
+
if ( that.s.iRightColumns > 0 ) {
|
20198 |
+
that.dom.grid.right.liner.scrollTop = that.dom.grid.left.liner.scrollTop;
|
20199 |
+
}
|
20200 |
+
}
|
20201 |
+
} )
|
20202 |
+
.on( wheelType, function(e) {
|
20203 |
+
// Pass horizontal scrolling through
|
20204 |
+
var xDelta = e.type === 'wheel' ?
|
20205 |
+
-e.originalEvent.deltaX :
|
20206 |
+
e.originalEvent.wheelDeltaX;
|
20207 |
+
that.dom.scroller.scrollLeft -= xDelta;
|
20208 |
+
} );
|
20209 |
+
}
|
20210 |
+
|
20211 |
+
if ( that.s.iRightColumns > 0 ) {
|
20212 |
+
// When scrolling the right column, scroll the body and the left column
|
20213 |
+
$(that.dom.grid.right.liner)
|
20214 |
+
.on( 'mouseover.DTFC touchstart.DTFC', function () {
|
20215 |
+
if ( ! mouseDown ) {
|
20216 |
+
mouseController = 'right';
|
20217 |
+
}
|
20218 |
+
} )
|
20219 |
+
.on( 'scroll.DTFC', function ( e ) {
|
20220 |
+
if ( ! mouseController && e.originalEvent ) {
|
20221 |
+
mouseController = 'right';
|
20222 |
+
}
|
20223 |
+
|
20224 |
+
if ( mouseController === 'right' ) {
|
20225 |
+
that.dom.scroller.scrollTop = that.dom.grid.right.liner.scrollTop;
|
20226 |
+
if ( that.s.iLeftColumns > 0 ) {
|
20227 |
+
that.dom.grid.left.liner.scrollTop = that.dom.grid.right.liner.scrollTop;
|
20228 |
+
}
|
20229 |
+
}
|
20230 |
+
} )
|
20231 |
+
.on( wheelType, function(e) {
|
20232 |
+
// Pass horizontal scrolling through
|
20233 |
+
var xDelta = e.type === 'wheel' ?
|
20234 |
+
-e.originalEvent.deltaX :
|
20235 |
+
e.originalEvent.wheelDeltaX;
|
20236 |
+
that.dom.scroller.scrollLeft -= xDelta;
|
20237 |
+
} );
|
20238 |
+
}
|
20239 |
+
|
20240 |
+
$(window).on( 'resize.DTFC', function () {
|
20241 |
+
that._fnGridLayout.call( that );
|
20242 |
+
} );
|
20243 |
+
|
20244 |
+
var bFirstDraw = true;
|
20245 |
+
var jqTable = $(this.s.dt.nTable);
|
20246 |
+
|
20247 |
+
jqTable
|
20248 |
+
.on( 'draw.dt.DTFC', function () {
|
20249 |
+
that._fnColCalc();
|
20250 |
+
that._fnDraw.call( that, bFirstDraw );
|
20251 |
+
bFirstDraw = false;
|
20252 |
+
} )
|
20253 |
+
.on( 'column-sizing.dt.DTFC', function () {
|
20254 |
+
that._fnColCalc();
|
20255 |
+
that._fnGridLayout( that );
|
20256 |
+
} )
|
20257 |
+
.on( 'column-visibility.dt.DTFC', function ( e, settings, column, vis, recalc ) {
|
20258 |
+
if ( recalc === undefined || recalc ) {
|
20259 |
+
that._fnColCalc();
|
20260 |
+
that._fnGridLayout( that );
|
20261 |
+
that._fnDraw( true );
|
20262 |
+
}
|
20263 |
+
} )
|
20264 |
+
.on( 'select.dt.DTFC deselect.dt.DTFC', function ( e, dt, type, indexes ) {
|
20265 |
+
if ( e.namespace === 'dt' ) {
|
20266 |
+
that._fnDraw( false );
|
20267 |
+
}
|
20268 |
+
} )
|
20269 |
+
.on( 'destroy.dt.DTFC', function () {
|
20270 |
+
jqTable.off( '.DTFC' );
|
20271 |
+
|
20272 |
+
$(that.dom.scroller).off( '.DTFC' );
|
20273 |
+
$(window).off( '.DTFC' );
|
20274 |
+
$(that.s.dt.nTableWrapper).off( '.DTFC' );
|
20275 |
+
|
20276 |
+
$(that.dom.grid.left.liner).off( '.DTFC '+wheelType );
|
20277 |
+
$(that.dom.grid.left.wrapper).remove();
|
20278 |
+
|
20279 |
+
$(that.dom.grid.right.liner).off( '.DTFC '+wheelType );
|
20280 |
+
$(that.dom.grid.right.wrapper).remove();
|
20281 |
+
} );
|
20282 |
+
|
20283 |
+
/* Get things right to start with - note that due to adjusting the columns, there must be
|
20284 |
+
* another redraw of the main table. It doesn't need to be a full redraw however.
|
20285 |
+
*/
|
20286 |
+
this._fnGridLayout();
|
20287 |
+
this.s.dt.oInstance.fnDraw(false);
|
20288 |
+
},
|
20289 |
+
|
20290 |
+
|
20291 |
+
/**
|
20292 |
+
* Calculate the column widths for the grid layout
|
20293 |
+
* @returns {void}
|
20294 |
+
* @private
|
20295 |
+
*/
|
20296 |
+
"_fnColCalc": function ()
|
20297 |
+
{
|
20298 |
+
var that = this;
|
20299 |
+
var iLeftWidth = 0;
|
20300 |
+
var iRightWidth = 0;
|
20301 |
+
|
20302 |
+
this.s.aiInnerWidths = [];
|
20303 |
+
this.s.aiOuterWidths = [];
|
20304 |
+
|
20305 |
+
$.each( this.s.dt.aoColumns, function (i, col) {
|
20306 |
+
var th = $(col.nTh);
|
20307 |
+
var border;
|
20308 |
+
|
20309 |
+
if ( ! th.filter(':visible').length ) {
|
20310 |
+
that.s.aiInnerWidths.push( 0 );
|
20311 |
+
that.s.aiOuterWidths.push( 0 );
|
20312 |
+
}
|
20313 |
+
else
|
20314 |
+
{
|
20315 |
+
// Inner width is used to assign widths to cells
|
20316 |
+
// Outer width is used to calculate the container
|
20317 |
+
var iWidth = th.outerWidth();
|
20318 |
+
|
20319 |
+
// When working with the left most-cell, need to add on the
|
20320 |
+
// table's border to the outerWidth, since we need to take
|
20321 |
+
// account of it, but it isn't in any cell
|
20322 |
+
if ( that.s.aiOuterWidths.length === 0 ) {
|
20323 |
+
border = $(that.s.dt.nTable).css('border-left-width');
|
20324 |
+
iWidth += typeof border === 'string' && border.indexOf('px') === -1 ?
|
20325 |
+
1 :
|
20326 |
+
parseInt( border, 10 );
|
20327 |
+
}
|
20328 |
+
|
20329 |
+
// Likewise with the final column on the right
|
20330 |
+
if ( that.s.aiOuterWidths.length === that.s.dt.aoColumns.length-1 ) {
|
20331 |
+
border = $(that.s.dt.nTable).css('border-right-width');
|
20332 |
+
iWidth += typeof border === 'string' && border.indexOf('px') === -1 ?
|
20333 |
+
1 :
|
20334 |
+
parseInt( border, 10 );
|
20335 |
+
}
|
20336 |
+
|
20337 |
+
that.s.aiOuterWidths.push( iWidth );
|
20338 |
+
that.s.aiInnerWidths.push( th.width() );
|
20339 |
+
|
20340 |
+
if ( i < that.s.iLeftColumns )
|
20341 |
+
{
|
20342 |
+
iLeftWidth += iWidth;
|
20343 |
+
}
|
20344 |
+
|
20345 |
+
if ( that.s.iTableColumns-that.s.iRightColumns <= i )
|
20346 |
+
{
|
20347 |
+
iRightWidth += iWidth;
|
20348 |
+
}
|
20349 |
+
}
|
20350 |
+
} );
|
20351 |
+
|
20352 |
+
this.s.iLeftWidth = iLeftWidth;
|
20353 |
+
this.s.iRightWidth = iRightWidth;
|
20354 |
+
},
|
20355 |
+
|
20356 |
+
|
20357 |
+
/**
|
20358 |
+
* Set up the DOM for the fixed column. The way the layout works is to create a 1x3 grid
|
20359 |
+
* for the left column, the DataTable (for which we just reuse the scrolling element DataTable
|
20360 |
+
* puts into the DOM) and the right column. In each of he two fixed column elements there is a
|
20361 |
+
* grouping wrapper element and then a head, body and footer wrapper. In each of these we then
|
20362 |
+
* place the cloned header, body or footer tables. This effectively gives as 3x3 grid structure.
|
20363 |
+
* @returns {void}
|
20364 |
+
* @private
|
20365 |
+
*/
|
20366 |
+
"_fnGridSetup": function ()
|
20367 |
+
{
|
20368 |
+
var that = this;
|
20369 |
+
var oOverflow = this._fnDTOverflow();
|
20370 |
+
var block;
|
20371 |
+
|
20372 |
+
this.dom.body = this.s.dt.nTable;
|
20373 |
+
this.dom.header = this.s.dt.nTHead.parentNode;
|
20374 |
+
this.dom.header.parentNode.parentNode.style.position = "relative";
|
20375 |
+
|
20376 |
+
var nSWrapper =
|
20377 |
+
$('<div class="DTFC_ScrollWrapper" style="position:relative; clear:both;">'+
|
20378 |
+
'<div class="DTFC_LeftWrapper" style="position:absolute; top:0; left:0;" aria-hidden="true">'+
|
20379 |
+
'<div class="DTFC_LeftHeadWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div>'+
|
20380 |
+
'<div class="DTFC_LeftBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;">'+
|
20381 |
+
'<div class="DTFC_LeftBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div>'+
|
20382 |
+
'</div>'+
|
20383 |
+
'<div class="DTFC_LeftFootWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div>'+
|
20384 |
+
'</div>'+
|
20385 |
+
'<div class="DTFC_RightWrapper" style="position:absolute; top:0; right:0;" aria-hidden="true">'+
|
20386 |
+
'<div class="DTFC_RightHeadWrapper" style="position:relative; top:0; left:0;">'+
|
20387 |
+
'<div class="DTFC_RightHeadBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div>'+
|
20388 |
+
'</div>'+
|
20389 |
+
'<div class="DTFC_RightBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;">'+
|
20390 |
+
'<div class="DTFC_RightBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div>'+
|
20391 |
+
'</div>'+
|
20392 |
+
'<div class="DTFC_RightFootWrapper" style="position:relative; top:0; left:0;">'+
|
20393 |
+
'<div class="DTFC_RightFootBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div>'+
|
20394 |
+
'</div>'+
|
20395 |
+
'</div>'+
|
20396 |
+
'</div>')[0];
|
20397 |
+
var nLeft = nSWrapper.childNodes[0];
|
20398 |
+
var nRight = nSWrapper.childNodes[1];
|
20399 |
+
|
20400 |
+
this.dom.grid.dt.parentNode.insertBefore( nSWrapper, this.dom.grid.dt );
|
20401 |
+
nSWrapper.appendChild( this.dom.grid.dt );
|
20402 |
+
|
20403 |
+
this.dom.grid.wrapper = nSWrapper;
|
20404 |
+
|
20405 |
+
if ( this.s.iLeftColumns > 0 )
|
20406 |
+
{
|
20407 |
+
this.dom.grid.left.wrapper = nLeft;
|
20408 |
+
this.dom.grid.left.head = nLeft.childNodes[0];
|
20409 |
+
this.dom.grid.left.body = nLeft.childNodes[1];
|
20410 |
+
this.dom.grid.left.liner = $('div.DTFC_LeftBodyLiner', nSWrapper)[0];
|
20411 |
+
|
20412 |
+
nSWrapper.appendChild( nLeft );
|
20413 |
+
}
|
20414 |
+
|
20415 |
+
if ( this.s.iRightColumns > 0 )
|
20416 |
+
{
|
20417 |
+
this.dom.grid.right.wrapper = nRight;
|
20418 |
+
this.dom.grid.right.head = nRight.childNodes[0];
|
20419 |
+
this.dom.grid.right.body = nRight.childNodes[1];
|
20420 |
+
this.dom.grid.right.liner = $('div.DTFC_RightBodyLiner', nSWrapper)[0];
|
20421 |
+
|
20422 |
+
nRight.style.right = oOverflow.bar+"px";
|
20423 |
+
|
20424 |
+
block = $('div.DTFC_RightHeadBlocker', nSWrapper)[0];
|
20425 |
+
block.style.width = oOverflow.bar+"px";
|
20426 |
+
block.style.right = -oOverflow.bar+"px";
|
20427 |
+
this.dom.grid.right.headBlock = block;
|
20428 |
+
|
20429 |
+
block = $('div.DTFC_RightFootBlocker', nSWrapper)[0];
|
20430 |
+
block.style.width = oOverflow.bar+"px";
|
20431 |
+
block.style.right = -oOverflow.bar+"px";
|
20432 |
+
this.dom.grid.right.footBlock = block;
|
20433 |
+
|
20434 |
+
nSWrapper.appendChild( nRight );
|
20435 |
+
}
|
20436 |
+
|
20437 |
+
if ( this.s.dt.nTFoot )
|
20438 |
+
{
|
20439 |
+
this.dom.footer = this.s.dt.nTFoot.parentNode;
|
20440 |
+
if ( this.s.iLeftColumns > 0 )
|
20441 |
+
{
|
20442 |
+
this.dom.grid.left.foot = nLeft.childNodes[2];
|
20443 |
+
}
|
20444 |
+
if ( this.s.iRightColumns > 0 )
|
20445 |
+
{
|
20446 |
+
this.dom.grid.right.foot = nRight.childNodes[2];
|
20447 |
+
}
|
20448 |
+
}
|
20449 |
+
|
20450 |
+
// RTL support - swap the position of the left and right columns (#48)
|
20451 |
+
if ( this.s.rtl ) {
|
20452 |
+
$('div.DTFC_RightHeadBlocker', nSWrapper).css( {
|
20453 |
+
left: -oOverflow.bar+'px',
|
20454 |
+
right: ''
|
20455 |
+
} );
|
20456 |
+
}
|
20457 |
+
},
|
20458 |
+
|
20459 |
+
|
20460 |
+
/**
|
20461 |
+
* Style and position the grid used for the FixedColumns layout
|
20462 |
+
* @returns {void}
|
20463 |
+
* @private
|
20464 |
+
*/
|
20465 |
+
"_fnGridLayout": function ()
|
20466 |
+
{
|
20467 |
+
var that = this;
|
20468 |
+
var oGrid = this.dom.grid;
|
20469 |
+
var iWidth = $(oGrid.wrapper).width();
|
20470 |
+
var iBodyHeight = this.s.dt.nTable.parentNode.offsetHeight;
|
20471 |
+
var iFullHeight = this.s.dt.nTable.parentNode.parentNode.offsetHeight;
|
20472 |
+
var oOverflow = this._fnDTOverflow();
|
20473 |
+
var iLeftWidth = this.s.iLeftWidth;
|
20474 |
+
var iRightWidth = this.s.iRightWidth;
|
20475 |
+
var rtl = $(this.dom.body).css('direction') === 'rtl';
|
20476 |
+
var wrapper;
|
20477 |
+
var scrollbarAdjust = function ( node, width ) {
|
20478 |
+
if ( ! oOverflow.bar ) {
|
20479 |
+
// If there is no scrollbar (Macs) we need to hide the auto scrollbar
|
20480 |
+
node.style.width = (width+20)+"px";
|
20481 |
+
node.style.paddingRight = "20px";
|
20482 |
+
node.style.boxSizing = "border-box";
|
20483 |
+
}
|
20484 |
+
else if ( that._firefoxScrollError() ) {
|
20485 |
+
// See the above function for why this is required
|
20486 |
+
if ( $(node).height() > 34 ) {
|
20487 |
+
node.style.width = (width+oOverflow.bar)+"px";
|
20488 |
+
}
|
20489 |
+
}
|
20490 |
+
else {
|
20491 |
+
// Otherwise just overflow by the scrollbar
|
20492 |
+
node.style.width = (width+oOverflow.bar)+"px";
|
20493 |
+
}
|
20494 |
+
};
|
20495 |
+
|
20496 |
+
// When x scrolling - don't paint the fixed columns over the x scrollbar
|
20497 |
+
if ( oOverflow.x )
|
20498 |
+
{
|
20499 |
+
iBodyHeight -= oOverflow.bar;
|
20500 |
+
}
|
20501 |
+
|
20502 |
+
oGrid.wrapper.style.height = iFullHeight+"px";
|
20503 |
+
|
20504 |
+
if ( this.s.iLeftColumns > 0 )
|
20505 |
+
{
|
20506 |
+
wrapper = oGrid.left.wrapper;
|
20507 |
+
wrapper.style.width = iLeftWidth+'px';
|
20508 |
+
wrapper.style.height = '1px';
|
20509 |
+
|
20510 |
+
// Swap the position of the left and right columns for rtl (#48)
|
20511 |
+
// This is always up against the edge, scrollbar on the far side
|
20512 |
+
if ( rtl ) {
|
20513 |
+
wrapper.style.left = '';
|
20514 |
+
wrapper.style.right = 0;
|
20515 |
+
}
|
20516 |
+
else {
|
20517 |
+
wrapper.style.left = 0;
|
20518 |
+
wrapper.style.right = '';
|
20519 |
+
}
|
20520 |
+
|
20521 |
+
oGrid.left.body.style.height = iBodyHeight+"px";
|
20522 |
+
if ( oGrid.left.foot ) {
|
20523 |
+
oGrid.left.foot.style.top = (oOverflow.x ? oOverflow.bar : 0)+"px"; // shift footer for scrollbar
|
20524 |
+
}
|
20525 |
+
|
20526 |
+
scrollbarAdjust( oGrid.left.liner, iLeftWidth );
|
20527 |
+
oGrid.left.liner.style.height = iBodyHeight+"px";
|
20528 |
+
oGrid.left.liner.style.maxHeight = iBodyHeight+"px";
|
20529 |
+
}
|
20530 |
+
|
20531 |
+
if ( this.s.iRightColumns > 0 )
|
20532 |
+
{
|
20533 |
+
wrapper = oGrid.right.wrapper;
|
20534 |
+
wrapper.style.width = iRightWidth+'px';
|
20535 |
+
wrapper.style.height = '1px';
|
20536 |
+
|
20537 |
+
// Need to take account of the vertical scrollbar
|
20538 |
+
if ( this.s.rtl ) {
|
20539 |
+
wrapper.style.left = oOverflow.y ? oOverflow.bar+'px' : 0;
|
20540 |
+
wrapper.style.right = '';
|
20541 |
+
}
|
20542 |
+
else {
|
20543 |
+
wrapper.style.left = '';
|
20544 |
+
wrapper.style.right = oOverflow.y ? oOverflow.bar+'px' : 0;
|
20545 |
+
}
|
20546 |
+
|
20547 |
+
oGrid.right.body.style.height = iBodyHeight+"px";
|
20548 |
+
if ( oGrid.right.foot ) {
|
20549 |
+
oGrid.right.foot.style.top = (oOverflow.x ? oOverflow.bar : 0)+"px";
|
20550 |
+
}
|
20551 |
+
|
20552 |
+
scrollbarAdjust( oGrid.right.liner, iRightWidth );
|
20553 |
+
oGrid.right.liner.style.height = iBodyHeight+"px";
|
20554 |
+
oGrid.right.liner.style.maxHeight = iBodyHeight+"px";
|
20555 |
+
|
20556 |
+
oGrid.right.headBlock.style.display = oOverflow.y ? 'block' : 'none';
|
20557 |
+
oGrid.right.footBlock.style.display = oOverflow.y ? 'block' : 'none';
|
20558 |
+
}
|
20559 |
+
},
|
20560 |
+
|
20561 |
+
|
20562 |
+
/**
|
20563 |
+
* Get information about the DataTable's scrolling state - specifically if the table is scrolling
|
20564 |
+
* on either the x or y axis, and also the scrollbar width.
|
20565 |
+
* @returns {object} Information about the DataTables scrolling state with the properties:
|
20566 |
+
* 'x', 'y' and 'bar'
|
20567 |
+
* @private
|
20568 |
+
*/
|
20569 |
+
"_fnDTOverflow": function ()
|
20570 |
+
{
|
20571 |
+
var nTable = this.s.dt.nTable;
|
20572 |
+
var nTableScrollBody = nTable.parentNode;
|
20573 |
+
var out = {
|
20574 |
+
"x": false,
|
20575 |
+
"y": false,
|
20576 |
+
"bar": this.s.dt.oScroll.iBarWidth
|
20577 |
+
};
|
20578 |
+
|
20579 |
+
if ( nTable.offsetWidth > nTableScrollBody.clientWidth )
|
20580 |
+
{
|
20581 |
+
out.x = true;
|
20582 |
+
}
|
20583 |
+
|
20584 |
+
if ( nTable.offsetHeight > nTableScrollBody.clientHeight )
|
20585 |
+
{
|
20586 |
+
out.y = true;
|
20587 |
+
}
|
20588 |
+
|
20589 |
+
return out;
|
20590 |
+
},
|
20591 |
+
|
20592 |
+
|
20593 |
+
/**
|
20594 |
+
* Clone and position the fixed columns
|
20595 |
+
* @returns {void}
|
20596 |
+
* @param {Boolean} bAll Indicate if the header and footer should be updated as well (true)
|
20597 |
+
* @private
|
20598 |
+
*/
|
20599 |
+
"_fnDraw": function ( bAll )
|
20600 |
+
{
|
20601 |
+
this._fnGridLayout();
|
20602 |
+
this._fnCloneLeft( bAll );
|
20603 |
+
this._fnCloneRight( bAll );
|
20604 |
+
|
20605 |
+
/* Draw callback function */
|
20606 |
+
if ( this.s.fnDrawCallback !== null )
|
20607 |
+
{
|
20608 |
+
this.s.fnDrawCallback.call( this, this.dom.clone.left, this.dom.clone.right );
|
20609 |
+
}
|
20610 |
+
|
20611 |
+
/* Event triggering */
|
20612 |
+
$(this).trigger( 'draw.dtfc', {
|
20613 |
+
"leftClone": this.dom.clone.left,
|
20614 |
+
"rightClone": this.dom.clone.right
|
20615 |
+
} );
|
20616 |
+
},
|
20617 |
+
|
20618 |
+
|
20619 |
+
/**
|
20620 |
+
* Clone the right columns
|
20621 |
+
* @returns {void}
|
20622 |
+
* @param {Boolean} bAll Indicate if the header and footer should be updated as well (true)
|
20623 |
+
* @private
|
20624 |
+
*/
|
20625 |
+
"_fnCloneRight": function ( bAll )
|
20626 |
+
{
|
20627 |
+
if ( this.s.iRightColumns <= 0 ) {
|
20628 |
+
return;
|
20629 |
+
}
|
20630 |
+
|
20631 |
+
var that = this,
|
20632 |
+
i, jq,
|
20633 |
+
aiColumns = [];
|
20634 |
+
|
20635 |
+
for ( i=this.s.iTableColumns-this.s.iRightColumns ; i<this.s.iTableColumns ; i++ ) {
|
20636 |
+
if ( this.s.dt.aoColumns[i].bVisible ) {
|
20637 |
+
aiColumns.push( i );
|
20638 |
+
}
|
20639 |
+
}
|
20640 |
+
|
20641 |
+
this._fnClone( this.dom.clone.right, this.dom.grid.right, aiColumns, bAll );
|
20642 |
+
},
|
20643 |
+
|
20644 |
+
|
20645 |
+
/**
|
20646 |
+
* Clone the left columns
|
20647 |
+
* @returns {void}
|
20648 |
+
* @param {Boolean} bAll Indicate if the header and footer should be updated as well (true)
|
20649 |
+
* @private
|
20650 |
+
*/
|
20651 |
+
"_fnCloneLeft": function ( bAll )
|
20652 |
+
{
|
20653 |
+
if ( this.s.iLeftColumns <= 0 ) {
|
20654 |
+
return;
|
20655 |
+
}
|
20656 |
+
|
20657 |
+
var that = this,
|
20658 |
+
i, jq,
|
20659 |
+
aiColumns = [];
|
20660 |
+
|
20661 |
+
for ( i=0 ; i<this.s.iLeftColumns ; i++ ) {
|
20662 |
+
if ( this.s.dt.aoColumns[i].bVisible ) {
|
20663 |
+
aiColumns.push( i );
|
20664 |
+
}
|
20665 |
+
}
|
20666 |
+
|
20667 |
+
this._fnClone( this.dom.clone.left, this.dom.grid.left, aiColumns, bAll );
|
20668 |
+
},
|
20669 |
+
|
20670 |
+
|
20671 |
+
/**
|
20672 |
+
* Make a copy of the layout object for a header or footer element from DataTables. Note that
|
20673 |
+
* this method will clone the nodes in the layout object.
|
20674 |
+
* @returns {Array} Copy of the layout array
|
20675 |
+
* @param {Object} aoOriginal Layout array from DataTables (aoHeader or aoFooter)
|
20676 |
+
* @param {Object} aiColumns Columns to copy
|
20677 |
+
* @param {boolean} events Copy cell events or not
|
20678 |
+
* @private
|
20679 |
+
*/
|
20680 |
+
"_fnCopyLayout": function ( aoOriginal, aiColumns, events )
|
20681 |
+
{
|
20682 |
+
var aReturn = [];
|
20683 |
+
var aClones = [];
|
20684 |
+
var aCloned = [];
|
20685 |
+
|
20686 |
+
for ( var i=0, iLen=aoOriginal.length ; i<iLen ; i++ )
|
20687 |
+
{
|
20688 |
+
var aRow = [];
|
20689 |
+
aRow.nTr = $(aoOriginal[i].nTr).clone(events, false)[0];
|
20690 |
+
|
20691 |
+
for ( var j=0, jLen=this.s.iTableColumns ; j<jLen ; j++ )
|
20692 |
+
{
|
20693 |
+
if ( $.inArray( j, aiColumns ) === -1 )
|
20694 |
+
{
|
20695 |
+
continue;
|
20696 |
+
}
|
20697 |
+
|
20698 |
+
var iCloned = $.inArray( aoOriginal[i][j].cell, aCloned );
|
20699 |
+
if ( iCloned === -1 )
|
20700 |
+
{
|
20701 |
+
var nClone = $(aoOriginal[i][j].cell).clone(events, false)[0];
|
20702 |
+
aClones.push( nClone );
|
20703 |
+
aCloned.push( aoOriginal[i][j].cell );
|
20704 |
+
|
20705 |
+
aRow.push( {
|
20706 |
+
"cell": nClone,
|
20707 |
+
"unique": aoOriginal[i][j].unique
|
20708 |
+
} );
|
20709 |
+
}
|
20710 |
+
else
|
20711 |
+
{
|
20712 |
+
aRow.push( {
|
20713 |
+
"cell": aClones[ iCloned ],
|
20714 |
+
"unique": aoOriginal[i][j].unique
|
20715 |
+
} );
|
20716 |
+
}
|
20717 |
+
}
|
20718 |
+
|
20719 |
+
aReturn.push( aRow );
|
20720 |
+
}
|
20721 |
+
|
20722 |
+
return aReturn;
|
20723 |
+
},
|
20724 |
+
|
20725 |
+
|
20726 |
+
/**
|
20727 |
+
* Clone the DataTable nodes and place them in the DOM (sized correctly)
|
20728 |
+
* @returns {void}
|
20729 |
+
* @param {Object} oClone Object containing the header, footer and body cloned DOM elements
|
20730 |
+
* @param {Object} oGrid Grid object containing the display grid elements for the cloned
|
20731 |
+
* column (left or right)
|
20732 |
+
* @param {Array} aiColumns Column indexes which should be operated on from the DataTable
|
20733 |
+
* @param {Boolean} bAll Indicate if the header and footer should be updated as well (true)
|
20734 |
+
* @private
|
20735 |
+
*/
|
20736 |
+
"_fnClone": function ( oClone, oGrid, aiColumns, bAll )
|
20737 |
+
{
|
20738 |
+
var that = this,
|
20739 |
+
i, iLen, j, jLen, jq, nTarget, iColumn, nClone, iIndex, aoCloneLayout,
|
20740 |
+
jqCloneThead, aoFixedHeader,
|
20741 |
+
dt = this.s.dt;
|
20742 |
+
|
20743 |
+
/*
|
20744 |
+
* Header
|
20745 |
+
*/
|
20746 |
+
if ( bAll )
|
20747 |
+
{
|
20748 |
+
$(oClone.header).remove();
|
20749 |
+
|
20750 |
+
oClone.header = $(this.dom.header).clone(true, false)[0];
|
20751 |
+
oClone.header.className += " DTFC_Cloned";
|
20752 |
+
oClone.header.style.width = "100%";
|
20753 |
+
oGrid.head.appendChild( oClone.header );
|
20754 |
+
|
20755 |
+
/* Copy the DataTables layout cache for the header for our floating column */
|
20756 |
+
aoCloneLayout = this._fnCopyLayout( dt.aoHeader, aiColumns, true );
|
20757 |
+
jqCloneThead = $('>thead', oClone.header);
|
20758 |
+
jqCloneThead.empty();
|
20759 |
+
|
20760 |
+
/* Add the created cloned TR elements to the table */
|
20761 |
+
for ( i=0, iLen=aoCloneLayout.length ; i<iLen ; i++ )
|
20762 |
+
{
|
20763 |
+
jqCloneThead[0].appendChild( aoCloneLayout[i].nTr );
|
20764 |
+
}
|
20765 |
+
|
20766 |
+
/* Use the handy _fnDrawHead function in DataTables to do the rowspan/colspan
|
20767 |
+
* calculations for us
|
20768 |
+
*/
|
20769 |
+
dt.oApi._fnDrawHead( dt, aoCloneLayout, true );
|
20770 |
+
}
|
20771 |
+
else
|
20772 |
+
{
|
20773 |
+
/* To ensure that we copy cell classes exactly, regardless of colspan, multiple rows
|
20774 |
+
* etc, we make a copy of the header from the DataTable again, but don't insert the
|
20775 |
+
* cloned cells, just copy the classes across. To get the matching layout for the
|
20776 |
+
* fixed component, we use the DataTables _fnDetectHeader method, allowing 1:1 mapping
|
20777 |
+
*/
|
20778 |
+
aoCloneLayout = this._fnCopyLayout( dt.aoHeader, aiColumns, false );
|
20779 |
+
aoFixedHeader=[];
|
20780 |
+
|
20781 |
+
dt.oApi._fnDetectHeader( aoFixedHeader, $('>thead', oClone.header)[0] );
|
20782 |
+
|
20783 |
+
for ( i=0, iLen=aoCloneLayout.length ; i<iLen ; i++ )
|
20784 |
+
{
|
20785 |
+
for ( j=0, jLen=aoCloneLayout[i].length ; j<jLen ; j++ )
|
20786 |
+
{
|
20787 |
+
aoFixedHeader[i][j].cell.className = aoCloneLayout[i][j].cell.className;
|
20788 |
+
|
20789 |
+
// If jQuery UI theming is used we need to copy those elements as well
|
20790 |
+
$('span.DataTables_sort_icon', aoFixedHeader[i][j].cell).each( function () {
|
20791 |
+
this.className = $('span.DataTables_sort_icon', aoCloneLayout[i][j].cell)[0].className;
|
20792 |
+
} );
|
20793 |
+
}
|
20794 |
+
}
|
20795 |
+
}
|
20796 |
+
this._fnEqualiseHeights( 'thead', this.dom.header, oClone.header );
|
20797 |
+
|
20798 |
+
/*
|
20799 |
+
* Body
|
20800 |
+
*/
|
20801 |
+
if ( this.s.sHeightMatch == 'auto' )
|
20802 |
+
{
|
20803 |
+
/* Remove any heights which have been applied already and let the browser figure it out */
|
20804 |
+
$('>tbody>tr', that.dom.body).css('height', 'auto');
|
20805 |
+
}
|
20806 |
+
|
20807 |
+
if ( oClone.body !== null )
|
20808 |
+
{
|
20809 |
+
$(oClone.body).remove();
|
20810 |
+
oClone.body = null;
|
20811 |
+
}
|
20812 |
+
|
20813 |
+
oClone.body = $(this.dom.body).clone(true)[0];
|
20814 |
+
oClone.body.className += " DTFC_Cloned";
|
20815 |
+
oClone.body.style.paddingBottom = dt.oScroll.iBarWidth+"px";
|
20816 |
+
oClone.body.style.marginBottom = (dt.oScroll.iBarWidth*2)+"px"; /* For IE */
|
20817 |
+
if ( oClone.body.getAttribute('id') !== null )
|
20818 |
+
{
|
20819 |
+
oClone.body.removeAttribute('id');
|
20820 |
+
}
|
20821 |
+
|
20822 |
+
$('>thead>tr', oClone.body).empty();
|
20823 |
+
$('>tfoot', oClone.body).remove();
|
20824 |
+
|
20825 |
+
var nBody = $('tbody', oClone.body)[0];
|
20826 |
+
$(nBody).empty();
|
20827 |
+
if ( dt.aiDisplay.length > 0 )
|
20828 |
+
{
|
20829 |
+
/* Copy the DataTables' header elements to force the column width in exactly the
|
20830 |
+
* same way that DataTables does it - have the header element, apply the width and
|
20831 |
+
* colapse it down
|
20832 |
+
*/
|
20833 |
+
var nInnerThead = $('>thead>tr', oClone.body)[0];
|
20834 |
+
for ( iIndex=0 ; iIndex<aiColumns.length ; iIndex++ )
|
20835 |
+
{
|
20836 |
+
iColumn = aiColumns[iIndex];
|
20837 |
+
|
20838 |
+
nClone = $(dt.aoColumns[iColumn].nTh).clone(true)[0];
|
20839 |
+
nClone.innerHTML = "";
|
20840 |
+
|
20841 |
+
var oStyle = nClone.style;
|
20842 |
+
oStyle.paddingTop = "0";
|
20843 |
+
oStyle.paddingBottom = "0";
|
20844 |
+
oStyle.borderTopWidth = "0";
|
20845 |
+
oStyle.borderBottomWidth = "0";
|
20846 |
+
oStyle.height = 0;
|
20847 |
+
oStyle.width = that.s.aiInnerWidths[iColumn]+"px";
|
20848 |
+
|
20849 |
+
nInnerThead.appendChild( nClone );
|
20850 |
+
}
|
20851 |
+
|
20852 |
+
/* Add in the tbody elements, cloning form the master table */
|
20853 |
+
$('>tbody>tr', that.dom.body).each( function (z) {
|
20854 |
+
var i = that.s.dt.oFeatures.bServerSide===false ?
|
20855 |
+
that.s.dt.aiDisplay[ that.s.dt._iDisplayStart+z ] : z;
|
20856 |
+
var aTds = that.s.dt.aoData[ i ].anCells || $(this).children('td, th');
|
20857 |
+
|
20858 |
+
var n = this.cloneNode(false);
|
20859 |
+
n.removeAttribute('id');
|
20860 |
+
n.setAttribute( 'data-dt-row', i );
|
20861 |
+
|
20862 |
+
for ( iIndex=0 ; iIndex<aiColumns.length ; iIndex++ )
|
20863 |
+
{
|
20864 |
+
iColumn = aiColumns[iIndex];
|
20865 |
+
|
20866 |
+
if ( aTds.length > 0 )
|
20867 |
+
{
|
20868 |
+
nClone = $( aTds[iColumn] ).clone(true, true)[0];
|
20869 |
+
nClone.removeAttribute( 'id' );
|
20870 |
+
nClone.setAttribute( 'data-dt-row', i );
|
20871 |
+
nClone.setAttribute( 'data-dt-column', dt.oApi._fnVisibleToColumnIndex( dt, iColumn ) );
|
20872 |
+
n.appendChild( nClone );
|
20873 |
+
}
|
20874 |
+
}
|
20875 |
+
nBody.appendChild( n );
|
20876 |
+
} );
|
20877 |
+
}
|
20878 |
+
else
|
20879 |
+
{
|
20880 |
+
$('>tbody>tr', that.dom.body).each( function (z) {
|
20881 |
+
nClone = this.cloneNode(true);
|
20882 |
+
nClone.className += ' DTFC_NoData';
|
20883 |
+
$('td', nClone).html('');
|
20884 |
+
nBody.appendChild( nClone );
|
20885 |
+
} );
|
20886 |
+
}
|
20887 |
+
|
20888 |
+
oClone.body.style.width = "100%";
|
20889 |
+
oClone.body.style.margin = "0";
|
20890 |
+
oClone.body.style.padding = "0";
|
20891 |
+
|
20892 |
+
// Interop with Scroller - need to use a height forcing element in the
|
20893 |
+
// scrolling area in the same way that Scroller does in the body scroll.
|
20894 |
+
if ( dt.oScroller !== undefined )
|
20895 |
+
{
|
20896 |
+
var scrollerForcer = dt.oScroller.dom.force;
|
20897 |
+
|
20898 |
+
if ( ! oGrid.forcer ) {
|
20899 |
+
oGrid.forcer = scrollerForcer.cloneNode( true );
|
20900 |
+
oGrid.liner.appendChild( oGrid.forcer );
|
20901 |
+
}
|
20902 |
+
else {
|
20903 |
+
oGrid.forcer.style.height = scrollerForcer.style.height;
|
20904 |
+
}
|
20905 |
+
}
|
20906 |
+
|
20907 |
+
oGrid.liner.appendChild( oClone.body );
|
20908 |
+
|
20909 |
+
this._fnEqualiseHeights( 'tbody', that.dom.body, oClone.body );
|
20910 |
+
|
20911 |
+
/*
|
20912 |
+
* Footer
|
20913 |
+
*/
|
20914 |
+
if ( dt.nTFoot !== null )
|
20915 |
+
{
|
20916 |
+
if ( bAll )
|
20917 |
+
{
|
20918 |
+
if ( oClone.footer !== null )
|
20919 |
+
{
|
20920 |
+
oClone.footer.parentNode.removeChild( oClone.footer );
|
20921 |
+
}
|
20922 |
+
oClone.footer = $(this.dom.footer).clone(true, true)[0];
|
20923 |
+
oClone.footer.className += " DTFC_Cloned";
|
20924 |
+
oClone.footer.style.width = "100%";
|
20925 |
+
oGrid.foot.appendChild( oClone.footer );
|
20926 |
+
|
20927 |
+
/* Copy the footer just like we do for the header */
|
20928 |
+
aoCloneLayout = this._fnCopyLayout( dt.aoFooter, aiColumns, true );
|
20929 |
+
var jqCloneTfoot = $('>tfoot', oClone.footer);
|
20930 |
+
jqCloneTfoot.empty();
|
20931 |
+
|
20932 |
+
for ( i=0, iLen=aoCloneLayout.length ; i<iLen ; i++ )
|
20933 |
+
{
|
20934 |
+
jqCloneTfoot[0].appendChild( aoCloneLayout[i].nTr );
|
20935 |
+
}
|
20936 |
+
dt.oApi._fnDrawHead( dt, aoCloneLayout, true );
|
20937 |
+
}
|
20938 |
+
else
|
20939 |
+
{
|
20940 |
+
aoCloneLayout = this._fnCopyLayout( dt.aoFooter, aiColumns, false );
|
20941 |
+
var aoCurrFooter=[];
|
20942 |
+
|
20943 |
+
dt.oApi._fnDetectHeader( aoCurrFooter, $('>tfoot', oClone.footer)[0] );
|
20944 |
+
|
20945 |
+
for ( i=0, iLen=aoCloneLayout.length ; i<iLen ; i++ )
|
20946 |
+
{
|
20947 |
+
for ( j=0, jLen=aoCloneLayout[i].length ; j<jLen ; j++ )
|
20948 |
+
{
|
20949 |
+
aoCurrFooter[i][j].cell.className = aoCloneLayout[i][j].cell.className;
|
20950 |
+
}
|
20951 |
+
}
|
20952 |
+
}
|
20953 |
+
this._fnEqualiseHeights( 'tfoot', this.dom.footer, oClone.footer );
|
20954 |
+
}
|
20955 |
+
|
20956 |
+
/* Equalise the column widths between the header footer and body - body get's priority */
|
20957 |
+
var anUnique = dt.oApi._fnGetUniqueThs( dt, $('>thead', oClone.header)[0] );
|
20958 |
+
$(anUnique).each( function (i) {
|
20959 |
+
iColumn = aiColumns[i];
|
20960 |
+
this.style.width = that.s.aiInnerWidths[iColumn]+"px";
|
20961 |
+
} );
|
20962 |
+
|
20963 |
+
if ( that.s.dt.nTFoot !== null )
|
20964 |
+
{
|
20965 |
+
anUnique = dt.oApi._fnGetUniqueThs( dt, $('>tfoot', oClone.footer)[0] );
|
20966 |
+
$(anUnique).each( function (i) {
|
20967 |
+
iColumn = aiColumns[i];
|
20968 |
+
this.style.width = that.s.aiInnerWidths[iColumn]+"px";
|
20969 |
+
} );
|
20970 |
+
}
|
20971 |
+
},
|
20972 |
+
|
20973 |
+
|
20974 |
+
/**
|
20975 |
+
* From a given table node (THEAD etc), get a list of TR direct child elements
|
20976 |
+
* @param {Node} nIn Table element to search for TR elements (THEAD, TBODY or TFOOT element)
|
20977 |
+
* @returns {Array} List of TR elements found
|
20978 |
+
* @private
|
20979 |
+
*/
|
20980 |
+
"_fnGetTrNodes": function ( nIn )
|
20981 |
+
{
|
20982 |
+
var aOut = [];
|
20983 |
+
for ( var i=0, iLen=nIn.childNodes.length ; i<iLen ; i++ )
|
20984 |
+
{
|
20985 |
+
if ( nIn.childNodes[i].nodeName.toUpperCase() == "TR" )
|
20986 |
+
{
|
20987 |
+
aOut.push( nIn.childNodes[i] );
|
20988 |
+
}
|
20989 |
+
}
|
20990 |
+
return aOut;
|
20991 |
+
},
|
20992 |
+
|
20993 |
+
|
20994 |
+
/**
|
20995 |
+
* Equalise the heights of the rows in a given table node in a cross browser way
|
20996 |
+
* @returns {void}
|
20997 |
+
* @param {String} nodeName Node type - thead, tbody or tfoot
|
20998 |
+
* @param {Node} original Original node to take the heights from
|
20999 |
+
* @param {Node} clone Copy the heights to
|
21000 |
+
* @private
|
21001 |
+
*/
|
21002 |
+
"_fnEqualiseHeights": function ( nodeName, original, clone )
|
21003 |
+
{
|
21004 |
+
if ( this.s.sHeightMatch == 'none' && nodeName !== 'thead' && nodeName !== 'tfoot' )
|
21005 |
+
{
|
21006 |
+
return;
|
21007 |
+
}
|
21008 |
+
|
21009 |
+
var that = this,
|
21010 |
+
i, iLen, iHeight, iHeight2, iHeightOriginal, iHeightClone,
|
21011 |
+
rootOriginal = original.getElementsByTagName(nodeName)[0],
|
21012 |
+
rootClone = clone.getElementsByTagName(nodeName)[0],
|
21013 |
+
jqBoxHack = $('>'+nodeName+'>tr:eq(0)', original).children(':first'),
|
21014 |
+
iBoxHack = jqBoxHack.outerHeight() - jqBoxHack.height(),
|
21015 |
+
anOriginal = this._fnGetTrNodes( rootOriginal ),
|
21016 |
+
anClone = this._fnGetTrNodes( rootClone ),
|
21017 |
+
heights = [];
|
21018 |
+
|
21019 |
+
for ( i=0, iLen=anClone.length ; i<iLen ; i++ )
|
21020 |
+
{
|
21021 |
+
iHeightOriginal = anOriginal[i].offsetHeight;
|
21022 |
+
iHeightClone = anClone[i].offsetHeight;
|
21023 |
+
iHeight = iHeightClone > iHeightOriginal ? iHeightClone : iHeightOriginal;
|
21024 |
+
|
21025 |
+
if ( this.s.sHeightMatch == 'semiauto' )
|
21026 |
+
{
|
21027 |
+
anOriginal[i]._DTTC_iHeight = iHeight;
|
21028 |
+
}
|
21029 |
+
|
21030 |
+
heights.push( iHeight );
|
21031 |
+
}
|
21032 |
+
|
21033 |
+
for ( i=0, iLen=anClone.length ; i<iLen ; i++ )
|
21034 |
+
{
|
21035 |
+
anClone[i].style.height = heights[i]+"px";
|
21036 |
+
anOriginal[i].style.height = heights[i]+"px";
|
21037 |
+
}
|
21038 |
+
},
|
21039 |
+
|
21040 |
+
/**
|
21041 |
+
* Determine if the UA suffers from Firefox's overflow:scroll scrollbars
|
21042 |
+
* not being shown bug.
|
21043 |
+
*
|
21044 |
+
* Firefox doesn't draw scrollbars, even if it is told to using
|
21045 |
+
* overflow:scroll, if the div is less than 34px height. See bugs 292284 and
|
21046 |
+
* 781885. Using UA detection here since this is particularly hard to detect
|
21047 |
+
* using objects - its a straight up rendering error in Firefox.
|
21048 |
+
*
|
21049 |
+
* @return {boolean} True if Firefox error is present, false otherwise
|
21050 |
+
*/
|
21051 |
+
_firefoxScrollError: function () {
|
21052 |
+
if ( _firefoxScroll === undefined ) {
|
21053 |
+
var test = $('<div/>')
|
21054 |
+
.css( {
|
21055 |
+
position: 'absolute',
|
21056 |
+
top: 0,
|
21057 |
+
left: 0,
|
21058 |
+
height: 10,
|
21059 |
+
width: 50,
|
21060 |
+
overflow: 'scroll'
|
21061 |
+
} )
|
21062 |
+
.appendTo( 'body' );
|
21063 |
+
|
21064 |
+
// Make sure this doesn't apply on Macs with 0 width scrollbars
|
21065 |
+
_firefoxScroll = (
|
21066 |
+
test[0].clientWidth === test[0].offsetWidth && this._fnDTOverflow().bar !== 0
|
21067 |
+
);
|
21068 |
+
|
21069 |
+
test.remove();
|
21070 |
+
}
|
21071 |
+
|
21072 |
+
return _firefoxScroll;
|
21073 |
+
}
|
21074 |
+
} );
|
21075 |
+
|
21076 |
+
|
21077 |
+
|
21078 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21079 |
+
* Statics
|
21080 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
21081 |
+
|
21082 |
+
/**
|
21083 |
+
* FixedColumns default settings for initialisation
|
21084 |
+
* @name FixedColumns.defaults
|
21085 |
+
* @namespace
|
21086 |
+
* @static
|
21087 |
+
*/
|
21088 |
+
FixedColumns.defaults = /** @lends FixedColumns.defaults */{
|
21089 |
+
/**
|
21090 |
+
* Number of left hand columns to fix in position
|
21091 |
+
* @type int
|
21092 |
+
* @default 1
|
21093 |
+
* @static
|
21094 |
+
* @example
|
21095 |
+
* var = $('#example').dataTable( {
|
21096 |
+
* "scrollX": "100%"
|
21097 |
+
* } );
|
21098 |
+
* new $.fn.dataTable.fixedColumns( table, {
|
21099 |
+
* "leftColumns": 2
|
21100 |
+
* } );
|
21101 |
+
*/
|
21102 |
+
"iLeftColumns": 1,
|
21103 |
+
|
21104 |
+
/**
|
21105 |
+
* Number of right hand columns to fix in position
|
21106 |
+
* @type int
|
21107 |
+
* @default 0
|
21108 |
+
* @static
|
21109 |
+
* @example
|
21110 |
+
* var table = $('#example').dataTable( {
|
21111 |
+
* "scrollX": "100%"
|
21112 |
+
* } );
|
21113 |
+
* new $.fn.dataTable.fixedColumns( table, {
|
21114 |
+
* "rightColumns": 1
|
21115 |
+
* } );
|
21116 |
+
*/
|
21117 |
+
"iRightColumns": 0,
|
21118 |
+
|
21119 |
+
/**
|
21120 |
+
* Draw callback function which is called when FixedColumns has redrawn the fixed assets
|
21121 |
+
* @type function(object, object):void
|
21122 |
+
* @default null
|
21123 |
+
* @static
|
21124 |
+
* @example
|
21125 |
+
* var table = $('#example').dataTable( {
|
21126 |
+
* "scrollX": "100%"
|
21127 |
+
* } );
|
21128 |
+
* new $.fn.dataTable.fixedColumns( table, {
|
21129 |
+
* "drawCallback": function () {
|
21130 |
+
* alert( "FixedColumns redraw" );
|
21131 |
+
* }
|
21132 |
+
* } );
|
21133 |
+
*/
|
21134 |
+
"fnDrawCallback": null,
|
21135 |
+
|
21136 |
+
/**
|
21137 |
+
* Height matching algorthim to use. This can be "none" which will result in no height
|
21138 |
+
* matching being applied by FixedColumns (height matching could be forced by CSS in this
|
21139 |
+
* case), "semiauto" whereby the height calculation will be performed once, and the result
|
21140 |
+
* cached to be used again (fnRecalculateHeight can be used to force recalculation), or
|
21141 |
+
* "auto" when height matching is performed on every draw (slowest but must accurate)
|
21142 |
+
* @type string
|
21143 |
+
* @default semiauto
|
21144 |
+
* @static
|
21145 |
+
* @example
|
21146 |
+
* var table = $('#example').dataTable( {
|
21147 |
+
* "scrollX": "100%"
|
21148 |
+
* } );
|
21149 |
+
* new $.fn.dataTable.fixedColumns( table, {
|
21150 |
+
* "heightMatch": "auto"
|
21151 |
+
* } );
|
21152 |
+
*/
|
21153 |
+
"sHeightMatch": "semiauto"
|
21154 |
+
};
|
21155 |
+
|
21156 |
+
|
21157 |
+
|
21158 |
+
|
21159 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21160 |
+
* Constants
|
21161 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
21162 |
+
|
21163 |
+
/**
|
21164 |
+
* FixedColumns version
|
21165 |
+
* @name FixedColumns.version
|
21166 |
+
* @type String
|
21167 |
+
* @default See code
|
21168 |
+
* @static
|
21169 |
+
*/
|
21170 |
+
FixedColumns.version = "3.2.4";
|
21171 |
+
|
21172 |
+
|
21173 |
+
|
21174 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21175 |
+
* DataTables API integration
|
21176 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
21177 |
+
|
21178 |
+
DataTable.Api.register( 'fixedColumns()', function () {
|
21179 |
+
return this;
|
21180 |
+
} );
|
21181 |
+
|
21182 |
+
DataTable.Api.register( 'fixedColumns().update()', function () {
|
21183 |
+
return this.iterator( 'table', function ( ctx ) {
|
21184 |
+
if ( ctx._oFixedColumns ) {
|
21185 |
+
ctx._oFixedColumns.fnUpdate();
|
21186 |
+
}
|
21187 |
+
} );
|
21188 |
+
} );
|
21189 |
+
|
21190 |
+
DataTable.Api.register( 'fixedColumns().relayout()', function () {
|
21191 |
+
return this.iterator( 'table', function ( ctx ) {
|
21192 |
+
if ( ctx._oFixedColumns ) {
|
21193 |
+
ctx._oFixedColumns.fnRedrawLayout();
|
21194 |
+
}
|
21195 |
+
} );
|
21196 |
+
} );
|
21197 |
+
|
21198 |
+
DataTable.Api.register( 'rows().recalcHeight()', function () {
|
21199 |
+
return this.iterator( 'row', function ( ctx, idx ) {
|
21200 |
+
if ( ctx._oFixedColumns ) {
|
21201 |
+
ctx._oFixedColumns.fnRecalculateHeight( this.row(idx).node() );
|
21202 |
+
}
|
21203 |
+
} );
|
21204 |
+
} );
|
21205 |
+
|
21206 |
+
DataTable.Api.register( 'fixedColumns().rowIndex()', function ( row ) {
|
21207 |
+
row = $(row);
|
21208 |
+
|
21209 |
+
return row.parents('.DTFC_Cloned').length ?
|
21210 |
+
this.rows( { page: 'current' } ).indexes()[ row.index() ] :
|
21211 |
+
this.row( row ).index();
|
21212 |
+
} );
|
21213 |
+
|
21214 |
+
DataTable.Api.register( 'fixedColumns().cellIndex()', function ( cell ) {
|
21215 |
+
cell = $(cell);
|
21216 |
+
|
21217 |
+
if ( cell.parents('.DTFC_Cloned').length ) {
|
21218 |
+
var rowClonedIdx = cell.parent().index();
|
21219 |
+
var rowIdx = this.rows( { page: 'current' } ).indexes()[ rowClonedIdx ];
|
21220 |
+
var columnIdx;
|
21221 |
+
|
21222 |
+
if ( cell.parents('.DTFC_LeftWrapper').length ) {
|
21223 |
+
columnIdx = cell.index();
|
21224 |
+
}
|
21225 |
+
else {
|
21226 |
+
var columns = this.columns().flatten().length;
|
21227 |
+
columnIdx = columns - this.context[0]._oFixedColumns.s.iRightColumns + cell.index();
|
21228 |
+
}
|
21229 |
+
|
21230 |
+
return {
|
21231 |
+
row: rowIdx,
|
21232 |
+
column: this.column.index( 'toData', columnIdx ),
|
21233 |
+
columnVisible: columnIdx
|
21234 |
+
};
|
21235 |
+
}
|
21236 |
+
else {
|
21237 |
+
return this.cell( cell ).index();
|
21238 |
+
}
|
21239 |
+
} );
|
21240 |
+
|
21241 |
+
|
21242 |
+
|
21243 |
+
|
21244 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21245 |
+
* Initialisation
|
21246 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
21247 |
+
|
21248 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
21249 |
+
// events so we can automatically initialise
|
21250 |
+
$(document).on( 'init.dt.fixedColumns', function (e, settings) {
|
21251 |
+
if ( e.namespace !== 'dt' ) {
|
21252 |
+
return;
|
21253 |
+
}
|
21254 |
+
|
21255 |
+
var init = settings.oInit.fixedColumns;
|
21256 |
+
var defaults = DataTable.defaults.fixedColumns;
|
21257 |
+
|
21258 |
+
if ( init || defaults ) {
|
21259 |
+
var opts = $.extend( {}, init, defaults );
|
21260 |
+
|
21261 |
+
if ( init !== false ) {
|
21262 |
+
new FixedColumns( settings, opts );
|
21263 |
+
}
|
21264 |
+
}
|
21265 |
+
} );
|
21266 |
+
|
21267 |
+
|
21268 |
+
|
21269 |
+
// Make FixedColumns accessible from the DataTables instance
|
21270 |
+
$.fn.dataTable.FixedColumns = FixedColumns;
|
21271 |
+
$.fn.DataTable.FixedColumns = FixedColumns;
|
21272 |
+
|
21273 |
+
return FixedColumns;
|
21274 |
+
}));
|
21275 |
+
|
21276 |
+
|
21277 |
+
/*! FixedHeader 3.1.3
|
21278 |
+
* ©2009-2017 SpryMedia Ltd - datatables.net/license
|
21279 |
+
*/
|
21280 |
+
|
21281 |
+
/**
|
21282 |
+
* @summary FixedHeader
|
21283 |
+
* @description Fix a table's header or footer, so it is always visible while
|
21284 |
+
* scrolling
|
21285 |
+
* @version 3.1.3
|
21286 |
+
* @file dataTables.fixedHeader.js
|
21287 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
21288 |
+
* @contact www.sprymedia.co.uk/contact
|
21289 |
+
* @copyright Copyright 2009-2017 SpryMedia Ltd.
|
21290 |
+
*
|
21291 |
+
* This source file is free software, available under the following license:
|
21292 |
+
* MIT license - http://datatables.net/license/mit
|
21293 |
+
*
|
21294 |
+
* This source file is distributed in the hope that it will be useful, but
|
21295 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
21296 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
21297 |
+
*
|
21298 |
+
* For details please refer to: http://www.datatables.net
|
21299 |
+
*/
|
21300 |
+
|
21301 |
+
(function( factory ){
|
21302 |
+
if ( typeof define === 'function' && define.amd ) {
|
21303 |
+
// AMD
|
21304 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
21305 |
+
return factory( $, window, document );
|
21306 |
+
} );
|
21307 |
+
}
|
21308 |
+
else if ( typeof exports === 'object' ) {
|
21309 |
+
// CommonJS
|
21310 |
+
module.exports = function (root, $) {
|
21311 |
+
if ( ! root ) {
|
21312 |
+
root = window;
|
21313 |
+
}
|
21314 |
+
|
21315 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
21316 |
+
$ = require('datatables.net')(root, $).$;
|
21317 |
+
}
|
21318 |
+
|
21319 |
+
return factory( $, root, root.document );
|
21320 |
+
};
|
21321 |
+
}
|
21322 |
+
else {
|
21323 |
+
// Browser
|
21324 |
+
factory( jQuery, window, document );
|
21325 |
+
}
|
21326 |
+
}(function( $, window, document, undefined ) {
|
21327 |
+
'use strict';
|
21328 |
+
var DataTable = $.fn.dataTable;
|
21329 |
+
|
21330 |
+
|
21331 |
+
var _instCounter = 0;
|
21332 |
+
|
21333 |
+
var FixedHeader = function ( dt, config ) {
|
21334 |
+
// Sanity check - you just know it will happen
|
21335 |
+
if ( ! (this instanceof FixedHeader) ) {
|
21336 |
+
throw "FixedHeader must be initialised with the 'new' keyword.";
|
21337 |
+
}
|
21338 |
+
|
21339 |
+
// Allow a boolean true for defaults
|
21340 |
+
if ( config === true ) {
|
21341 |
+
config = {};
|
21342 |
+
}
|
21343 |
+
|
21344 |
+
dt = new DataTable.Api( dt );
|
21345 |
+
|
21346 |
+
this.c = $.extend( true, {}, FixedHeader.defaults, config );
|
21347 |
+
|
21348 |
+
this.s = {
|
21349 |
+
dt: dt,
|
21350 |
+
position: {
|
21351 |
+
theadTop: 0,
|
21352 |
+
tbodyTop: 0,
|
21353 |
+
tfootTop: 0,
|
21354 |
+
tfootBottom: 0,
|
21355 |
+
width: 0,
|
21356 |
+
left: 0,
|
21357 |
+
tfootHeight: 0,
|
21358 |
+
theadHeight: 0,
|
21359 |
+
windowHeight: $(window).height(),
|
21360 |
+
visible: true
|
21361 |
+
},
|
21362 |
+
headerMode: null,
|
21363 |
+
footerMode: null,
|
21364 |
+
autoWidth: dt.settings()[0].oFeatures.bAutoWidth,
|
21365 |
+
namespace: '.dtfc'+(_instCounter++),
|
21366 |
+
scrollLeft: {
|
21367 |
+
header: -1,
|
21368 |
+
footer: -1
|
21369 |
+
},
|
21370 |
+
enable: true
|
21371 |
+
};
|
21372 |
+
|
21373 |
+
this.dom = {
|
21374 |
+
floatingHeader: null,
|
21375 |
+
thead: $(dt.table().header()),
|
21376 |
+
tbody: $(dt.table().body()),
|
21377 |
+
tfoot: $(dt.table().footer()),
|
21378 |
+
header: {
|
21379 |
+
host: null,
|
21380 |
+
floating: null,
|
21381 |
+
placeholder: null
|
21382 |
+
},
|
21383 |
+
footer: {
|
21384 |
+
host: null,
|
21385 |
+
floating: null,
|
21386 |
+
placeholder: null
|
21387 |
+
}
|
21388 |
+
};
|
21389 |
+
|
21390 |
+
this.dom.header.host = this.dom.thead.parent();
|
21391 |
+
this.dom.footer.host = this.dom.tfoot.parent();
|
21392 |
+
|
21393 |
+
var dtSettings = dt.settings()[0];
|
21394 |
+
if ( dtSettings._fixedHeader ) {
|
21395 |
+
throw "FixedHeader already initialised on table "+dtSettings.nTable.id;
|
21396 |
+
}
|
21397 |
+
|
21398 |
+
dtSettings._fixedHeader = this;
|
21399 |
+
|
21400 |
+
this._constructor();
|
21401 |
+
};
|
21402 |
+
|
21403 |
+
|
21404 |
+
/*
|
21405 |
+
* Variable: FixedHeader
|
21406 |
+
* Purpose: Prototype for FixedHeader
|
21407 |
+
* Scope: global
|
21408 |
+
*/
|
21409 |
+
$.extend( FixedHeader.prototype, {
|
21410 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21411 |
+
* API methods
|
21412 |
+
*/
|
21413 |
+
|
21414 |
+
/**
|
21415 |
+
* Enable / disable the fixed elements
|
21416 |
+
*
|
21417 |
+
* @param {boolean} enable `true` to enable, `false` to disable
|
21418 |
+
*/
|
21419 |
+
enable: function ( enable )
|
21420 |
+
{
|
21421 |
+
this.s.enable = enable;
|
21422 |
+
|
21423 |
+
if ( this.c.header ) {
|
21424 |
+
this._modeChange( 'in-place', 'header', true );
|
21425 |
+
}
|
21426 |
+
|
21427 |
+
if ( this.c.footer && this.dom.tfoot.length ) {
|
21428 |
+
this._modeChange( 'in-place', 'footer', true );
|
21429 |
+
}
|
21430 |
+
|
21431 |
+
this.update();
|
21432 |
+
},
|
21433 |
+
|
21434 |
+
/**
|
21435 |
+
* Set header offset
|
21436 |
+
*
|
21437 |
+
* @param {int} new value for headerOffset
|
21438 |
+
*/
|
21439 |
+
headerOffset: function ( offset )
|
21440 |
+
{
|
21441 |
+
if ( offset !== undefined ) {
|
21442 |
+
this.c.headerOffset = offset;
|
21443 |
+
this.update();
|
21444 |
+
}
|
21445 |
+
|
21446 |
+
return this.c.headerOffset;
|
21447 |
+
},
|
21448 |
+
|
21449 |
+
/**
|
21450 |
+
* Set footer offset
|
21451 |
+
*
|
21452 |
+
* @param {int} new value for footerOffset
|
21453 |
+
*/
|
21454 |
+
footerOffset: function ( offset )
|
21455 |
+
{
|
21456 |
+
if ( offset !== undefined ) {
|
21457 |
+
this.c.footerOffset = offset;
|
21458 |
+
this.update();
|
21459 |
+
}
|
21460 |
+
|
21461 |
+
return this.c.footerOffset;
|
21462 |
+
},
|
21463 |
+
|
21464 |
+
|
21465 |
+
/**
|
21466 |
+
* Recalculate the position of the fixed elements and force them into place
|
21467 |
+
*/
|
21468 |
+
update: function ()
|
21469 |
+
{
|
21470 |
+
this._positions();
|
21471 |
+
this._scroll( true );
|
21472 |
+
},
|
21473 |
+
|
21474 |
+
|
21475 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21476 |
+
* Constructor
|
21477 |
+
*/
|
21478 |
+
|
21479 |
+
/**
|
21480 |
+
* FixedHeader constructor - adding the required event listeners and
|
21481 |
+
* simple initialisation
|
21482 |
+
*
|
21483 |
+
* @private
|
21484 |
+
*/
|
21485 |
+
_constructor: function ()
|
21486 |
+
{
|
21487 |
+
var that = this;
|
21488 |
+
var dt = this.s.dt;
|
21489 |
+
|
21490 |
+
$(window)
|
21491 |
+
.on( 'scroll'+this.s.namespace, function () {
|
21492 |
+
that._scroll();
|
21493 |
+
} )
|
21494 |
+
.on( 'resize'+this.s.namespace, function () {
|
21495 |
+
that.s.position.windowHeight = $(window).height();
|
21496 |
+
that.update();
|
21497 |
+
} );
|
21498 |
+
|
21499 |
+
var autoHeader = $('.fh-fixedHeader');
|
21500 |
+
if ( ! this.c.headerOffset && autoHeader.length ) {
|
21501 |
+
this.c.headerOffset = autoHeader.outerHeight();
|
21502 |
+
}
|
21503 |
+
|
21504 |
+
var autoFooter = $('.fh-fixedFooter');
|
21505 |
+
if ( ! this.c.footerOffset && autoFooter.length ) {
|
21506 |
+
this.c.footerOffset = autoFooter.outerHeight();
|
21507 |
+
}
|
21508 |
+
|
21509 |
+
dt.on( 'column-reorder.dt.dtfc column-visibility.dt.dtfc draw.dt.dtfc column-sizing.dt.dtfc', function () {
|
21510 |
+
that.update();
|
21511 |
+
} );
|
21512 |
+
|
21513 |
+
dt.on( 'destroy.dtfc', function () {
|
21514 |
+
dt.off( '.dtfc' );
|
21515 |
+
$(window).off( that.s.namespace );
|
21516 |
+
} );
|
21517 |
+
|
21518 |
+
this._positions();
|
21519 |
+
this._scroll();
|
21520 |
+
},
|
21521 |
+
|
21522 |
+
|
21523 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21524 |
+
* Private methods
|
21525 |
+
*/
|
21526 |
+
|
21527 |
+
/**
|
21528 |
+
* Clone a fixed item to act as a place holder for the original element
|
21529 |
+
* which is moved into a clone of the table element, and moved around the
|
21530 |
+
* document to give the fixed effect.
|
21531 |
+
*
|
21532 |
+
* @param {string} item 'header' or 'footer'
|
21533 |
+
* @param {boolean} force Force the clone to happen, or allow automatic
|
21534 |
+
* decision (reuse existing if available)
|
21535 |
+
* @private
|
21536 |
+
*/
|
21537 |
+
_clone: function ( item, force )
|
21538 |
+
{
|
21539 |
+
var dt = this.s.dt;
|
21540 |
+
var itemDom = this.dom[ item ];
|
21541 |
+
var itemElement = item === 'header' ?
|
21542 |
+
this.dom.thead :
|
21543 |
+
this.dom.tfoot;
|
21544 |
+
|
21545 |
+
if ( ! force && itemDom.floating ) {
|
21546 |
+
// existing floating element - reuse it
|
21547 |
+
itemDom.floating.removeClass( 'fixedHeader-floating fixedHeader-locked' );
|
21548 |
+
}
|
21549 |
+
else {
|
21550 |
+
if ( itemDom.floating ) {
|
21551 |
+
itemDom.placeholder.remove();
|
21552 |
+
this._unsize( item );
|
21553 |
+
itemDom.floating.children().detach();
|
21554 |
+
itemDom.floating.remove();
|
21555 |
+
}
|
21556 |
+
|
21557 |
+
itemDom.floating = $( dt.table().node().cloneNode( false ) )
|
21558 |
+
.css( 'table-layout', 'fixed' )
|
21559 |
+
.removeAttr( 'id' )
|
21560 |
+
.append( itemElement )
|
21561 |
+
.appendTo( 'body' );
|
21562 |
+
|
21563 |
+
// Insert a fake thead/tfoot into the DataTable to stop it jumping around
|
21564 |
+
itemDom.placeholder = itemElement.clone( false )
|
21565 |
+
itemDom.placeholder
|
21566 |
+
.find( '*[id]' )
|
21567 |
+
.removeAttr( 'id' );
|
21568 |
+
|
21569 |
+
itemDom.host.prepend( itemDom.placeholder );
|
21570 |
+
|
21571 |
+
// Clone widths
|
21572 |
+
this._matchWidths( itemDom.placeholder, itemDom.floating );
|
21573 |
+
}
|
21574 |
+
},
|
21575 |
+
|
21576 |
+
/**
|
21577 |
+
* Copy widths from the cells in one element to another. This is required
|
21578 |
+
* for the footer as the footer in the main table takes its sizes from the
|
21579 |
+
* header columns. That isn't present in the footer so to have it still
|
21580 |
+
* align correctly, the sizes need to be copied over. It is also required
|
21581 |
+
* for the header when auto width is not enabled
|
21582 |
+
*
|
21583 |
+
* @param {jQuery} from Copy widths from
|
21584 |
+
* @param {jQuery} to Copy widths to
|
21585 |
+
* @private
|
21586 |
+
*/
|
21587 |
+
_matchWidths: function ( from, to ) {
|
21588 |
+
var get = function ( name ) {
|
21589 |
+
return $(name, from)
|
21590 |
+
.map( function () {
|
21591 |
+
return $(this).width();
|
21592 |
+
} ).toArray();
|
21593 |
+
};
|
21594 |
+
|
21595 |
+
var set = function ( name, toWidths ) {
|
21596 |
+
$(name, to).each( function ( i ) {
|
21597 |
+
$(this).css( {
|
21598 |
+
width: toWidths[i],
|
21599 |
+
minWidth: toWidths[i]
|
21600 |
+
} );
|
21601 |
+
} );
|
21602 |
+
};
|
21603 |
+
|
21604 |
+
var thWidths = get( 'th' );
|
21605 |
+
var tdWidths = get( 'td' );
|
21606 |
+
|
21607 |
+
set( 'th', thWidths );
|
21608 |
+
set( 'td', tdWidths );
|
21609 |
+
},
|
21610 |
+
|
21611 |
+
/**
|
21612 |
+
* Remove assigned widths from the cells in an element. This is required
|
21613 |
+
* when inserting the footer back into the main table so the size is defined
|
21614 |
+
* by the header columns and also when auto width is disabled in the
|
21615 |
+
* DataTable.
|
21616 |
+
*
|
21617 |
+
* @param {string} item The `header` or `footer`
|
21618 |
+
* @private
|
21619 |
+
*/
|
21620 |
+
_unsize: function ( item ) {
|
21621 |
+
var el = this.dom[ item ].floating;
|
21622 |
+
|
21623 |
+
if ( el && (item === 'footer' || (item === 'header' && ! this.s.autoWidth)) ) {
|
21624 |
+
$('th, td', el).css( {
|
21625 |
+
width: '',
|
21626 |
+
minWidth: ''
|
21627 |
+
} );
|
21628 |
+
}
|
21629 |
+
else if ( el && item === 'header' ) {
|
21630 |
+
$('th, td', el).css( 'min-width', '' );
|
21631 |
+
}
|
21632 |
+
},
|
21633 |
+
|
21634 |
+
/**
|
21635 |
+
* Reposition the floating elements to take account of horizontal page
|
21636 |
+
* scroll
|
21637 |
+
*
|
21638 |
+
* @param {string} item The `header` or `footer`
|
21639 |
+
* @param {int} scrollLeft Document scrollLeft
|
21640 |
+
* @private
|
21641 |
+
*/
|
21642 |
+
_horizontal: function ( item, scrollLeft )
|
21643 |
+
{
|
21644 |
+
var itemDom = this.dom[ item ];
|
21645 |
+
var position = this.s.position;
|
21646 |
+
var lastScrollLeft = this.s.scrollLeft;
|
21647 |
+
|
21648 |
+
if ( itemDom.floating && lastScrollLeft[ item ] !== scrollLeft ) {
|
21649 |
+
itemDom.floating.css( 'left', position.left - scrollLeft );
|
21650 |
+
|
21651 |
+
lastScrollLeft[ item ] = scrollLeft;
|
21652 |
+
}
|
21653 |
+
},
|
21654 |
+
|
21655 |
+
/**
|
21656 |
+
* Change from one display mode to another. Each fixed item can be in one
|
21657 |
+
* of:
|
21658 |
+
*
|
21659 |
+
* * `in-place` - In the main DataTable
|
21660 |
+
* * `in` - Floating over the DataTable
|
21661 |
+
* * `below` - (Header only) Fixed to the bottom of the table body
|
21662 |
+
* * `above` - (Footer only) Fixed to the top of the table body
|
21663 |
+
*
|
21664 |
+
* @param {string} mode Mode that the item should be shown in
|
21665 |
+
* @param {string} item 'header' or 'footer'
|
21666 |
+
* @param {boolean} forceChange Force a redraw of the mode, even if already
|
21667 |
+
* in that mode.
|
21668 |
+
* @private
|
21669 |
+
*/
|
21670 |
+
_modeChange: function ( mode, item, forceChange )
|
21671 |
+
{
|
21672 |
+
var dt = this.s.dt;
|
21673 |
+
var itemDom = this.dom[ item ];
|
21674 |
+
var position = this.s.position;
|
21675 |
+
|
21676 |
+
// Record focus. Browser's will cause input elements to loose focus if
|
21677 |
+
// they are inserted else where in the doc
|
21678 |
+
var tablePart = this.dom[ item==='footer' ? 'tfoot' : 'thead' ];
|
21679 |
+
var focus = $.contains( tablePart[0], document.activeElement ) ?
|
21680 |
+
document.activeElement :
|
21681 |
+
null;
|
21682 |
+
|
21683 |
+
if ( mode === 'in-place' ) {
|
21684 |
+
// Insert the header back into the table's real header
|
21685 |
+
if ( itemDom.placeholder ) {
|
21686 |
+
itemDom.placeholder.remove();
|
21687 |
+
itemDom.placeholder = null;
|
21688 |
+
}
|
21689 |
+
|
21690 |
+
this._unsize( item );
|
21691 |
+
|
21692 |
+
if ( item === 'header' ) {
|
21693 |
+
itemDom.host.prepend( this.dom.thead );
|
21694 |
+
}
|
21695 |
+
else {
|
21696 |
+
itemDom.host.append( this.dom.tfoot );
|
21697 |
+
}
|
21698 |
+
|
21699 |
+
if ( itemDom.floating ) {
|
21700 |
+
itemDom.floating.remove();
|
21701 |
+
itemDom.floating = null;
|
21702 |
+
}
|
21703 |
+
}
|
21704 |
+
else if ( mode === 'in' ) {
|
21705 |
+
// Remove the header from the read header and insert into a fixed
|
21706 |
+
// positioned floating table clone
|
21707 |
+
this._clone( item, forceChange );
|
21708 |
+
|
21709 |
+
itemDom.floating
|
21710 |
+
.addClass( 'fixedHeader-floating' )
|
21711 |
+
.css( item === 'header' ? 'top' : 'bottom', this.c[item+'Offset'] )
|
21712 |
+
.css( 'left', position.left+'px' )
|
21713 |
+
.css( 'width', position.width+'px' );
|
21714 |
+
|
21715 |
+
if ( item === 'footer' ) {
|
21716 |
+
itemDom.floating.css( 'top', '' );
|
21717 |
+
}
|
21718 |
+
}
|
21719 |
+
else if ( mode === 'below' ) { // only used for the header
|
21720 |
+
// Fix the position of the floating header at base of the table body
|
21721 |
+
this._clone( item, forceChange );
|
21722 |
+
|
21723 |
+
itemDom.floating
|
21724 |
+
.addClass( 'fixedHeader-locked' )
|
21725 |
+
.css( 'top', position.tfootTop - position.theadHeight )
|
21726 |
+
.css( 'left', position.left+'px' )
|
21727 |
+
.css( 'width', position.width+'px' );
|
21728 |
+
}
|
21729 |
+
else if ( mode === 'above' ) { // only used for the footer
|
21730 |
+
// Fix the position of the floating footer at top of the table body
|
21731 |
+
this._clone( item, forceChange );
|
21732 |
+
|
21733 |
+
itemDom.floating
|
21734 |
+
.addClass( 'fixedHeader-locked' )
|
21735 |
+
.css( 'top', position.tbodyTop )
|
21736 |
+
.css( 'left', position.left+'px' )
|
21737 |
+
.css( 'width', position.width+'px' );
|
21738 |
+
}
|
21739 |
+
|
21740 |
+
// Restore focus if it was lost
|
21741 |
+
if ( focus && focus !== document.activeElement ) {
|
21742 |
+
focus.focus();
|
21743 |
+
}
|
21744 |
+
|
21745 |
+
this.s.scrollLeft.header = -1;
|
21746 |
+
this.s.scrollLeft.footer = -1;
|
21747 |
+
this.s[item+'Mode'] = mode;
|
21748 |
+
},
|
21749 |
+
|
21750 |
+
/**
|
21751 |
+
* Cache the positional information that is required for the mode
|
21752 |
+
* calculations that FixedHeader performs.
|
21753 |
+
*
|
21754 |
+
* @private
|
21755 |
+
*/
|
21756 |
+
_positions: function ()
|
21757 |
+
{
|
21758 |
+
var dt = this.s.dt;
|
21759 |
+
var table = dt.table();
|
21760 |
+
var position = this.s.position;
|
21761 |
+
var dom = this.dom;
|
21762 |
+
var tableNode = $(table.node());
|
21763 |
+
|
21764 |
+
// Need to use the header and footer that are in the main table,
|
21765 |
+
// regardless of if they are clones, since they hold the positions we
|
21766 |
+
// want to measure from
|
21767 |
+
var thead = tableNode.children('thead');
|
21768 |
+
var tfoot = tableNode.children('tfoot');
|
21769 |
+
var tbody = dom.tbody;
|
21770 |
+
|
21771 |
+
position.visible = tableNode.is(':visible');
|
21772 |
+
position.width = tableNode.outerWidth();
|
21773 |
+
position.left = tableNode.offset().left;
|
21774 |
+
position.theadTop = thead.offset().top;
|
21775 |
+
position.tbodyTop = tbody.offset().top;
|
21776 |
+
position.theadHeight = position.tbodyTop - position.theadTop;
|
21777 |
+
|
21778 |
+
if ( tfoot.length ) {
|
21779 |
+
position.tfootTop = tfoot.offset().top;
|
21780 |
+
position.tfootBottom = position.tfootTop + tfoot.outerHeight();
|
21781 |
+
position.tfootHeight = position.tfootBottom - position.tfootTop;
|
21782 |
+
}
|
21783 |
+
else {
|
21784 |
+
position.tfootTop = position.tbodyTop + tbody.outerHeight();
|
21785 |
+
position.tfootBottom = position.tfootTop;
|
21786 |
+
position.tfootHeight = position.tfootTop;
|
21787 |
+
}
|
21788 |
+
},
|
21789 |
+
|
21790 |
+
|
21791 |
+
/**
|
21792 |
+
* Mode calculation - determine what mode the fixed items should be placed
|
21793 |
+
* into.
|
21794 |
+
*
|
21795 |
+
* @param {boolean} forceChange Force a redraw of the mode, even if already
|
21796 |
+
* in that mode.
|
21797 |
+
* @private
|
21798 |
+
*/
|
21799 |
+
_scroll: function ( forceChange )
|
21800 |
+
{
|
21801 |
+
var windowTop = $(document).scrollTop();
|
21802 |
+
var windowLeft = $(document).scrollLeft();
|
21803 |
+
var position = this.s.position;
|
21804 |
+
var headerMode, footerMode;
|
21805 |
+
|
21806 |
+
if ( ! this.s.enable ) {
|
21807 |
+
return;
|
21808 |
+
}
|
21809 |
+
|
21810 |
+
if ( this.c.header ) {
|
21811 |
+
if ( ! position.visible || windowTop <= position.theadTop - this.c.headerOffset ) {
|
21812 |
+
headerMode = 'in-place';
|
21813 |
+
}
|
21814 |
+
else if ( windowTop <= position.tfootTop - position.theadHeight - this.c.headerOffset ) {
|
21815 |
+
headerMode = 'in';
|
21816 |
+
}
|
21817 |
+
else {
|
21818 |
+
headerMode = 'below';
|
21819 |
+
}
|
21820 |
+
|
21821 |
+
if ( forceChange || headerMode !== this.s.headerMode ) {
|
21822 |
+
this._modeChange( headerMode, 'header', forceChange );
|
21823 |
+
}
|
21824 |
+
|
21825 |
+
this._horizontal( 'header', windowLeft );
|
21826 |
+
}
|
21827 |
+
|
21828 |
+
if ( this.c.footer && this.dom.tfoot.length ) {
|
21829 |
+
if ( ! position.visible || windowTop + position.windowHeight >= position.tfootBottom + this.c.footerOffset ) {
|
21830 |
+
footerMode = 'in-place';
|
21831 |
+
}
|
21832 |
+
else if ( position.windowHeight + windowTop > position.tbodyTop + position.tfootHeight + this.c.footerOffset ) {
|
21833 |
+
footerMode = 'in';
|
21834 |
+
}
|
21835 |
+
else {
|
21836 |
+
footerMode = 'above';
|
21837 |
+
}
|
21838 |
+
|
21839 |
+
if ( forceChange || footerMode !== this.s.footerMode ) {
|
21840 |
+
this._modeChange( footerMode, 'footer', forceChange );
|
21841 |
+
}
|
21842 |
+
|
21843 |
+
this._horizontal( 'footer', windowLeft );
|
21844 |
+
}
|
21845 |
+
}
|
21846 |
+
} );
|
21847 |
+
|
21848 |
+
|
21849 |
+
/**
|
21850 |
+
* Version
|
21851 |
+
* @type {String}
|
21852 |
+
* @static
|
21853 |
+
*/
|
21854 |
+
FixedHeader.version = "3.1.3";
|
21855 |
+
|
21856 |
+
/**
|
21857 |
+
* Defaults
|
21858 |
+
* @type {Object}
|
21859 |
+
* @static
|
21860 |
+
*/
|
21861 |
+
FixedHeader.defaults = {
|
21862 |
+
header: true,
|
21863 |
+
footer: false,
|
21864 |
+
headerOffset: 0,
|
21865 |
+
footerOffset: 0
|
21866 |
+
};
|
21867 |
+
|
21868 |
+
|
21869 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
21870 |
+
* DataTables interfaces
|
21871 |
+
*/
|
21872 |
+
|
21873 |
+
// Attach for constructor access
|
21874 |
+
$.fn.dataTable.FixedHeader = FixedHeader;
|
21875 |
+
$.fn.DataTable.FixedHeader = FixedHeader;
|
21876 |
+
|
21877 |
+
|
21878 |
+
// DataTables creation - check if the FixedHeader option has been defined on the
|
21879 |
+
// table and if so, initialise
|
21880 |
+
$(document).on( 'init.dt.dtfh', function (e, settings, json) {
|
21881 |
+
if ( e.namespace !== 'dt' ) {
|
21882 |
+
return;
|
21883 |
+
}
|
21884 |
+
|
21885 |
+
var init = settings.oInit.fixedHeader;
|
21886 |
+
var defaults = DataTable.defaults.fixedHeader;
|
21887 |
+
|
21888 |
+
if ( (init || defaults) && ! settings._fixedHeader ) {
|
21889 |
+
var opts = $.extend( {}, defaults, init );
|
21890 |
+
|
21891 |
+
if ( init !== false ) {
|
21892 |
+
new FixedHeader( settings, opts );
|
21893 |
+
}
|
21894 |
+
}
|
21895 |
+
} );
|
21896 |
+
|
21897 |
+
// DataTables API methods
|
21898 |
+
DataTable.Api.register( 'fixedHeader()', function () {} );
|
21899 |
+
|
21900 |
+
DataTable.Api.register( 'fixedHeader.adjust()', function () {
|
21901 |
+
return this.iterator( 'table', function ( ctx ) {
|
21902 |
+
var fh = ctx._fixedHeader;
|
21903 |
+
|
21904 |
+
if ( fh ) {
|
21905 |
+
fh.update();
|
21906 |
+
}
|
21907 |
+
} );
|
21908 |
+
} );
|
21909 |
+
|
21910 |
+
DataTable.Api.register( 'fixedHeader.enable()', function ( flag ) {
|
21911 |
+
return this.iterator( 'table', function ( ctx ) {
|
21912 |
+
var fh = ctx._fixedHeader;
|
21913 |
+
|
21914 |
+
flag = ( flag !== undefined ? flag : true );
|
21915 |
+
if ( fh && flag !== fh.s.enable ) {
|
21916 |
+
fh.enable( flag );
|
21917 |
+
}
|
21918 |
+
} );
|
21919 |
+
} );
|
21920 |
+
|
21921 |
+
DataTable.Api.register( 'fixedHeader.disable()', function ( ) {
|
21922 |
+
return this.iterator( 'table', function ( ctx ) {
|
21923 |
+
var fh = ctx._fixedHeader;
|
21924 |
+
|
21925 |
+
if ( fh && fh.s.enable ) {
|
21926 |
+
fh.enable( false );
|
21927 |
+
}
|
21928 |
+
} );
|
21929 |
+
} );
|
21930 |
+
|
21931 |
+
$.each( ['header', 'footer'], function ( i, el ) {
|
21932 |
+
DataTable.Api.register( 'fixedHeader.'+el+'Offset()', function ( offset ) {
|
21933 |
+
var ctx = this.context;
|
21934 |
+
|
21935 |
+
if ( offset === undefined ) {
|
21936 |
+
return ctx.length && ctx[0]._fixedHeader ?
|
21937 |
+
ctx[0]._fixedHeader[el +'Offset']() :
|
21938 |
+
undefined;
|
21939 |
+
}
|
21940 |
+
|
21941 |
+
return this.iterator( 'table', function ( ctx ) {
|
21942 |
+
var fh = ctx._fixedHeader;
|
21943 |
+
|
21944 |
+
if ( fh ) {
|
21945 |
+
fh[ el +'Offset' ]( offset );
|
21946 |
+
}
|
21947 |
+
} );
|
21948 |
+
} );
|
21949 |
+
} );
|
21950 |
+
|
21951 |
+
|
21952 |
+
return FixedHeader;
|
21953 |
+
}));
|
21954 |
+
|
21955 |
+
|
21956 |
+
/*! KeyTable 2.3.2
|
21957 |
+
* ©2009-2017 SpryMedia Ltd - datatables.net/license
|
21958 |
+
*/
|
21959 |
+
|
21960 |
+
/**
|
21961 |
+
* @summary KeyTable
|
21962 |
+
* @description Spreadsheet like keyboard navigation for DataTables
|
21963 |
+
* @version 2.3.2
|
21964 |
+
* @file dataTables.keyTable.js
|
21965 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
21966 |
+
* @contact www.sprymedia.co.uk/contact
|
21967 |
+
* @copyright Copyright 2009-2017 SpryMedia Ltd.
|
21968 |
+
*
|
21969 |
+
* This source file is free software, available under the following license:
|
21970 |
+
* MIT license - http://datatables.net/license/mit
|
21971 |
+
*
|
21972 |
+
* This source file is distributed in the hope that it will be useful, but
|
21973 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
21974 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
21975 |
+
*
|
21976 |
+
* For details please refer to: http://www.datatables.net
|
21977 |
+
*/
|
21978 |
+
|
21979 |
+
(function( factory ){
|
21980 |
+
if ( typeof define === 'function' && define.amd ) {
|
21981 |
+
// AMD
|
21982 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
21983 |
+
return factory( $, window, document );
|
21984 |
+
} );
|
21985 |
+
}
|
21986 |
+
else if ( typeof exports === 'object' ) {
|
21987 |
+
// CommonJS
|
21988 |
+
module.exports = function (root, $) {
|
21989 |
+
if ( ! root ) {
|
21990 |
+
root = window;
|
21991 |
+
}
|
21992 |
+
|
21993 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
21994 |
+
$ = require('datatables.net')(root, $).$;
|
21995 |
+
}
|
21996 |
+
|
21997 |
+
return factory( $, root, root.document );
|
21998 |
+
};
|
21999 |
+
}
|
22000 |
+
else {
|
22001 |
+
// Browser
|
22002 |
+
factory( jQuery, window, document );
|
22003 |
+
}
|
22004 |
+
}(function( $, window, document, undefined ) {
|
22005 |
+
'use strict';
|
22006 |
+
var DataTable = $.fn.dataTable;
|
22007 |
+
|
22008 |
+
|
22009 |
+
var KeyTable = function ( dt, opts ) {
|
22010 |
+
// Sanity check that we are using DataTables 1.10 or newer
|
22011 |
+
if ( ! DataTable.versionCheck || ! DataTable.versionCheck( '1.10.8' ) ) {
|
22012 |
+
throw 'KeyTable requires DataTables 1.10.8 or newer';
|
22013 |
+
}
|
22014 |
+
|
22015 |
+
// User and defaults configuration object
|
22016 |
+
this.c = $.extend( true, {},
|
22017 |
+
DataTable.defaults.keyTable,
|
22018 |
+
KeyTable.defaults,
|
22019 |
+
opts
|
22020 |
+
);
|
22021 |
+
|
22022 |
+
// Internal settings
|
22023 |
+
this.s = {
|
22024 |
+
/** @type {DataTable.Api} DataTables' API instance */
|
22025 |
+
dt: new DataTable.Api( dt ),
|
22026 |
+
|
22027 |
+
enable: true,
|
22028 |
+
|
22029 |
+
/** @type {bool} Flag for if a draw is triggered by focus */
|
22030 |
+
focusDraw: false,
|
22031 |
+
|
22032 |
+
/** @type {bool} Flag to indicate when waiting for a draw to happen.
|
22033 |
+
* Will ignore key presses at this point
|
22034 |
+
*/
|
22035 |
+
waitingForDraw: false,
|
22036 |
+
|
22037 |
+
/** @type {object} Information about the last cell that was focused */
|
22038 |
+
lastFocus: null
|
22039 |
+
};
|
22040 |
+
|
22041 |
+
// DOM items
|
22042 |
+
this.dom = {
|
22043 |
+
|
22044 |
+
};
|
22045 |
+
|
22046 |
+
// Check if row reorder has already been initialised on this table
|
22047 |
+
var settings = this.s.dt.settings()[0];
|
22048 |
+
var exisiting = settings.keytable;
|
22049 |
+
if ( exisiting ) {
|
22050 |
+
return exisiting;
|
22051 |
+
}
|
22052 |
+
|
22053 |
+
settings.keytable = this;
|
22054 |
+
this._constructor();
|
22055 |
+
};
|
22056 |
+
|
22057 |
+
|
22058 |
+
$.extend( KeyTable.prototype, {
|
22059 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
22060 |
+
* API methods for DataTables API interface
|
22061 |
+
*/
|
22062 |
+
|
22063 |
+
/**
|
22064 |
+
* Blur the table's cell focus
|
22065 |
+
*/
|
22066 |
+
blur: function ()
|
22067 |
+
{
|
22068 |
+
this._blur();
|
22069 |
+
},
|
22070 |
+
|
22071 |
+
/**
|
22072 |
+
* Enable cell focus for the table
|
22073 |
+
*
|
22074 |
+
* @param {string} state Can be `true`, `false` or `-string navigation-only`
|
22075 |
+
*/
|
22076 |
+
enable: function ( state )
|
22077 |
+
{
|
22078 |
+
this.s.enable = state;
|
22079 |
+
},
|
22080 |
+
|
22081 |
+
/**
|
22082 |
+
* Focus on a cell
|
22083 |
+
* @param {integer} row Row index
|
22084 |
+
* @param {integer} column Column index
|
22085 |
+
*/
|
22086 |
+
focus: function ( row, column )
|
22087 |
+
{
|
22088 |
+
this._focus( this.s.dt.cell( row, column ) );
|
22089 |
+
},
|
22090 |
+
|
22091 |
+
/**
|
22092 |
+
* Is the cell focused
|
22093 |
+
* @param {object} cell Cell index to check
|
22094 |
+
* @returns {boolean} true if focused, false otherwise
|
22095 |
+
*/
|
22096 |
+
focused: function ( cell )
|
22097 |
+
{
|
22098 |
+
var lastFocus = this.s.lastFocus;
|
22099 |
+
|
22100 |
+
if ( ! lastFocus ) {
|
22101 |
+
return false;
|
22102 |
+
}
|
22103 |
+
|
22104 |
+
var lastIdx = this.s.lastFocus.cell.index();
|
22105 |
+
return cell.row === lastIdx.row && cell.column === lastIdx.column;
|
22106 |
+
},
|
22107 |
+
|
22108 |
+
|
22109 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
22110 |
+
* Constructor
|
22111 |
+
*/
|
22112 |
+
|
22113 |
+
/**
|
22114 |
+
* Initialise the KeyTable instance
|
22115 |
+
*
|
22116 |
+
* @private
|
22117 |
+
*/
|
22118 |
+
_constructor: function ()
|
22119 |
+
{
|
22120 |
+
this._tabInput();
|
22121 |
+
|
22122 |
+
var that = this;
|
22123 |
+
var dt = this.s.dt;
|
22124 |
+
var table = $( dt.table().node() );
|
22125 |
+
|
22126 |
+
// Need to be able to calculate the cell positions relative to the table
|
22127 |
+
if ( table.css('position') === 'static' ) {
|
22128 |
+
table.css( 'position', 'relative' );
|
22129 |
+
}
|
22130 |
+
|
22131 |
+
// Click to focus
|
22132 |
+
$( dt.table().body() ).on( 'click.keyTable', 'th, td', function (e) {
|
22133 |
+
if ( that.s.enable === false ) {
|
22134 |
+
return;
|
22135 |
+
}
|
22136 |
+
|
22137 |
+
var cell = dt.cell( this );
|
22138 |
+
|
22139 |
+
if ( ! cell.any() ) {
|
22140 |
+
return;
|
22141 |
+
}
|
22142 |
+
|
22143 |
+
that._focus( cell, null, false, e );
|
22144 |
+
} );
|
22145 |
+
|
22146 |
+
// Key events
|
22147 |
+
$( document ).on( 'keydown.keyTable', function (e) {
|
22148 |
+
that._key( e );
|
22149 |
+
} );
|
22150 |
+
|
22151 |
+
// Click blur
|
22152 |
+
if ( this.c.blurable ) {
|
22153 |
+
$( document ).on( 'mousedown.keyTable', function ( e ) {
|
22154 |
+
// Click on the search input will blur focus
|
22155 |
+
if ( $(e.target).parents( '.dataTables_filter' ).length ) {
|
22156 |
+
that._blur();
|
22157 |
+
}
|
22158 |
+
|
22159 |
+
// If the click was inside the DataTables container, don't blur
|
22160 |
+
if ( $(e.target).parents().filter( dt.table().container() ).length ) {
|
22161 |
+
return;
|
22162 |
+
}
|
22163 |
+
|
22164 |
+
// Don't blur in Editor form
|
22165 |
+
if ( $(e.target).parents('div.DTE').length ) {
|
22166 |
+
return;
|
22167 |
+
}
|
22168 |
+
|
22169 |
+
// Or an Editor date input
|
22170 |
+
if ( $(e.target).parents('div.editor-datetime').length ) {
|
22171 |
+
return;
|
22172 |
+
}
|
22173 |
+
|
22174 |
+
//If the click was inside the fixed columns container, don't blur
|
22175 |
+
if ( $(e.target).parents().filter('.DTFC_Cloned').length ) {
|
22176 |
+
return;
|
22177 |
+
}
|
22178 |
+
|
22179 |
+
that._blur();
|
22180 |
+
} );
|
22181 |
+
}
|
22182 |
+
|
22183 |
+
if ( this.c.editor ) {
|
22184 |
+
var editor = this.c.editor;
|
22185 |
+
|
22186 |
+
// Need to disable KeyTable when the main editor is shown
|
22187 |
+
editor.on( 'open.keyTableMain', function (e, mode, action) {
|
22188 |
+
if ( mode !== 'inline' && that.s.enable ) {
|
22189 |
+
that.enable( false );
|
22190 |
+
|
22191 |
+
editor.one( 'close.keyTable', function () {
|
22192 |
+
that.enable( true );
|
22193 |
+
} );
|
22194 |
+
}
|
22195 |
+
} );
|
22196 |
+
|
22197 |
+
if ( this.c.editOnFocus ) {
|
22198 |
+
dt.on( 'key-focus.keyTable key-refocus.keyTable', function ( e, dt, cell, orig ) {
|
22199 |
+
that._editor( null, orig );
|
22200 |
+
} );
|
22201 |
+
}
|
22202 |
+
|
22203 |
+
// Activate Editor when a key is pressed (will be ignored, if
|
22204 |
+
// already active).
|
22205 |
+
dt.on( 'key.keyTable', function ( e, dt, key, cell, orig ) {
|
22206 |
+
that._editor( key, orig );
|
22207 |
+
} );
|
22208 |
+
}
|
22209 |
+
|
22210 |
+
// Stave saving
|
22211 |
+
if ( dt.settings()[0].oFeatures.bStateSave ) {
|
22212 |
+
dt.on( 'stateSaveParams.keyTable', function (e, s, d) {
|
22213 |
+
d.keyTable = that.s.lastFocus ?
|
22214 |
+
that.s.lastFocus.cell.index() :
|
22215 |
+
null;
|
22216 |
+
} );
|
22217 |
+
}
|
22218 |
+
|
22219 |
+
// Redraw - retain focus on the current cell
|
22220 |
+
dt.on( 'draw.keyTable', function (e) {
|
22221 |
+
if ( that.s.focusDraw ) {
|
22222 |
+
return;
|
22223 |
+
}
|
22224 |
+
|
22225 |
+
var lastFocus = that.s.lastFocus;
|
22226 |
+
|
22227 |
+
if ( lastFocus && lastFocus.node && $(lastFocus.node).closest('body') === document.body ) {
|
22228 |
+
var relative = that.s.lastFocus.relative;
|
22229 |
+
var info = dt.page.info();
|
22230 |
+
var row = relative.row + info.start;
|
22231 |
+
|
22232 |
+
if ( info.recordsDisplay === 0 ) {
|
22233 |
+
return;
|
22234 |
+
}
|
22235 |
+
|
22236 |
+
// Reverse if needed
|
22237 |
+
if ( row >= info.recordsDisplay ) {
|
22238 |
+
row = info.recordsDisplay - 1;
|
22239 |
+
}
|
22240 |
+
|
22241 |
+
that._focus( row, relative.column, true, e );
|
22242 |
+
}
|
22243 |
+
} );
|
22244 |
+
|
22245 |
+
dt.on( 'destroy.keyTable', function () {
|
22246 |
+
dt.off( '.keyTable' );
|
22247 |
+
$( dt.table().body() ).off( 'click.keyTable', 'th, td' );
|
22248 |
+
$( document.body )
|
22249 |
+
.off( 'keydown.keyTable' )
|
22250 |
+
.off( 'click.keyTable' );
|
22251 |
+
} );
|
22252 |
+
|
22253 |
+
// Initial focus comes from state or options
|
22254 |
+
var state = dt.state.loaded();
|
22255 |
+
|
22256 |
+
if ( state && state.keyTable ) {
|
22257 |
+
// Wait until init is done
|
22258 |
+
dt.one( 'init', function () {
|
22259 |
+
var cell = dt.cell( state.keyTable );
|
22260 |
+
|
22261 |
+
// Ensure that the saved cell still exists
|
22262 |
+
if ( cell.any() ) {
|
22263 |
+
cell.focus();
|
22264 |
+
}
|
22265 |
+
} );
|
22266 |
+
}
|
22267 |
+
else if ( this.c.focus ) {
|
22268 |
+
dt.cell( this.c.focus ).focus();
|
22269 |
+
}
|
22270 |
+
},
|
22271 |
+
|
22272 |
+
|
22273 |
+
|
22274 |
+
|
22275 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
22276 |
+
* Private methods
|
22277 |
+
*/
|
22278 |
+
|
22279 |
+
/**
|
22280 |
+
* Blur the control
|
22281 |
+
*
|
22282 |
+
* @private
|
22283 |
+
*/
|
22284 |
+
_blur: function ()
|
22285 |
+
{
|
22286 |
+
if ( ! this.s.enable || ! this.s.lastFocus ) {
|
22287 |
+
return;
|
22288 |
+
}
|
22289 |
+
|
22290 |
+
var cell = this.s.lastFocus.cell;
|
22291 |
+
|
22292 |
+
$( cell.node() ).removeClass( this.c.className );
|
22293 |
+
this.s.lastFocus = null;
|
22294 |
+
|
22295 |
+
this._updateFixedColumns(cell.index().column);
|
22296 |
+
|
22297 |
+
this._emitEvent( 'key-blur', [ this.s.dt, cell ] );
|
22298 |
+
},
|
22299 |
+
|
22300 |
+
/**
|
22301 |
+
* Copy text from the focused cell to clipboard
|
22302 |
+
*
|
22303 |
+
* @private
|
22304 |
+
*/
|
22305 |
+
_clipboardCopy: function ()
|
22306 |
+
{
|
22307 |
+
var dt = this.s.dt;
|
22308 |
+
|
22309 |
+
// If there is a cell focused, and there is no other text selected
|
22310 |
+
// allow the focused cell's text to be copied to clipboard
|
22311 |
+
if ( this.s.lastFocus && window.getSelection && !window.getSelection().toString() ) {
|
22312 |
+
var cell = this.s.lastFocus.cell;
|
22313 |
+
var text = cell.render('display');
|
22314 |
+
var hiddenDiv = $('<div/>')
|
22315 |
+
.css( {
|
22316 |
+
height: 1,
|
22317 |
+
width: 1,
|
22318 |
+
overflow: 'hidden',
|
22319 |
+
position: 'fixed',
|
22320 |
+
top: 0,
|
22321 |
+
left: 0
|
22322 |
+
} );
|
22323 |
+
var textarea = $('<textarea readonly/>')
|
22324 |
+
.val( text )
|
22325 |
+
.appendTo( hiddenDiv );
|
22326 |
+
|
22327 |
+
try {
|
22328 |
+
hiddenDiv.appendTo( dt.table().container() );
|
22329 |
+
textarea[0].focus();
|
22330 |
+
textarea[0].select();
|
22331 |
+
|
22332 |
+
document.execCommand( 'copy' );
|
22333 |
+
}
|
22334 |
+
catch (e) {}
|
22335 |
+
|
22336 |
+
hiddenDiv.remove();
|
22337 |
+
}
|
22338 |
+
},
|
22339 |
+
|
22340 |
+
|
22341 |
+
/**
|
22342 |
+
* Get an array of the column indexes that KeyTable can operate on. This
|
22343 |
+
* is a merge of the user supplied columns and the visible columns.
|
22344 |
+
*
|
22345 |
+
* @private
|
22346 |
+
*/
|
22347 |
+
_columns: function ()
|
22348 |
+
{
|
22349 |
+
var dt = this.s.dt;
|
22350 |
+
var user = dt.columns( this.c.columns ).indexes();
|
22351 |
+
var out = [];
|
22352 |
+
|
22353 |
+
dt.columns( ':visible' ).every( function (i) {
|
22354 |
+
if ( user.indexOf( i ) !== -1 ) {
|
22355 |
+
out.push( i );
|
22356 |
+
}
|
22357 |
+
} );
|
22358 |
+
|
22359 |
+
return out;
|
22360 |
+
},
|
22361 |
+
|
22362 |
+
|
22363 |
+
/**
|
22364 |
+
* Perform excel like navigation for Editor by triggering an edit on key
|
22365 |
+
* press
|
22366 |
+
*
|
22367 |
+
* @param {integer} key Key code for the pressed key
|
22368 |
+
* @param {object} orig Original event
|
22369 |
+
* @private
|
22370 |
+
*/
|
22371 |
+
_editor: function ( key, orig )
|
22372 |
+
{
|
22373 |
+
var that = this;
|
22374 |
+
var dt = this.s.dt;
|
22375 |
+
var editor = this.c.editor;
|
22376 |
+
|
22377 |
+
// Do nothing if there is already an inline edit in this cell
|
22378 |
+
if ( $('div.DTE', this.s.lastFocus.cell.node()).length ) {
|
22379 |
+
return;
|
22380 |
+
}
|
22381 |
+
|
22382 |
+
// Don't activate inline editing when the shift key is pressed
|
22383 |
+
if ( key === 16 ) {
|
22384 |
+
return;
|
22385 |
+
}
|
22386 |
+
|
22387 |
+
orig.stopPropagation();
|
22388 |
+
|
22389 |
+
// Return key should do nothing - for textareas it would empty the
|
22390 |
+
// contents
|
22391 |
+
if ( key === 13 ) {
|
22392 |
+
orig.preventDefault();
|
22393 |
+
}
|
22394 |
+
|
22395 |
+
editor
|
22396 |
+
.one( 'open.keyTable', function () {
|
22397 |
+
// Remove cancel open
|
22398 |
+
editor.off( 'cancelOpen.keyTable' );
|
22399 |
+
|
22400 |
+
// Excel style - select all text
|
22401 |
+
if ( that.c.editAutoSelect ) {
|
22402 |
+
$('div.DTE_Field_InputControl input, div.DTE_Field_InputControl textarea').select();
|
22403 |
+
}
|
22404 |
+
|
22405 |
+
// Reduce the keys the Keys listens for
|
22406 |
+
dt.keys.enable( that.c.editorKeys );
|
22407 |
+
|
22408 |
+
// On blur of the navigation submit
|
22409 |
+
dt.one( 'key-blur.editor', function () {
|
22410 |
+
if ( editor.displayed() ) {
|
22411 |
+
editor.submit();
|
22412 |
+
}
|
22413 |
+
} );
|
22414 |
+
|
22415 |
+
// Restore full key navigation on close
|
22416 |
+
editor.one( 'close', function () {
|
22417 |
+
dt.keys.enable( true );
|
22418 |
+
dt.off( 'key-blur.editor' );
|
22419 |
+
} );
|
22420 |
+
} )
|
22421 |
+
.one( 'cancelOpen.keyTable', function () {
|
22422 |
+
// `preOpen` can cancel the display of the form, so it
|
22423 |
+
// might be that the open event handler isn't needed
|
22424 |
+
editor.off( 'open.keyTable' );
|
22425 |
+
} )
|
22426 |
+
.inline( this.s.lastFocus.cell.index() );
|
22427 |
+
},
|
22428 |
+
|
22429 |
+
|
22430 |
+
/**
|
22431 |
+
* Emit an event on the DataTable for listeners
|
22432 |
+
*
|
22433 |
+
* @param {string} name Event name
|
22434 |
+
* @param {array} args Event arguments
|
22435 |
+
* @private
|
22436 |
+
*/
|
22437 |
+
_emitEvent: function ( name, args )
|
22438 |
+
{
|
22439 |
+
this.s.dt.iterator( 'table', function ( ctx, i ) {
|
22440 |
+
$(ctx.nTable).triggerHandler( name, args );
|
22441 |
+
} );
|
22442 |
+
},
|
22443 |
+
|
22444 |
+
|
22445 |
+
/**
|
22446 |
+
* Focus on a particular cell, shifting the table's paging if required
|
22447 |
+
*
|
22448 |
+
* @param {DataTables.Api|integer} row Can be given as an API instance that
|
22449 |
+
* contains the cell to focus or as an integer. As the latter it is the
|
22450 |
+
* visible row index (from the whole data set) - NOT the data index
|
22451 |
+
* @param {integer} [column] Not required if a cell is given as the first
|
22452 |
+
* parameter. Otherwise this is the column data index for the cell to
|
22453 |
+
* focus on
|
22454 |
+
* @param {boolean} [shift=true] Should the viewport be moved to show cell
|
22455 |
+
* @private
|
22456 |
+
*/
|
22457 |
+
_focus: function ( row, column, shift, originalEvent )
|
22458 |
+
{
|
22459 |
+
var that = this;
|
22460 |
+
var dt = this.s.dt;
|
22461 |
+
var pageInfo = dt.page.info();
|
22462 |
+
var lastFocus = this.s.lastFocus;
|
22463 |
+
|
22464 |
+
if ( ! originalEvent) {
|
22465 |
+
originalEvent = null;
|
22466 |
+
}
|
22467 |
+
|
22468 |
+
if ( ! this.s.enable ) {
|
22469 |
+
return;
|
22470 |
+
}
|
22471 |
+
|
22472 |
+
if ( typeof row !== 'number' ) {
|
22473 |
+
// Convert the cell to a row and column
|
22474 |
+
var index = row.index();
|
22475 |
+
column = index.column;
|
22476 |
+
row = dt
|
22477 |
+
.rows( { filter: 'applied', order: 'applied' } )
|
22478 |
+
.indexes()
|
22479 |
+
.indexOf( index.row );
|
22480 |
+
|
22481 |
+
// For server-side processing normalise the row by adding the start
|
22482 |
+
// point, since `rows().indexes()` includes only rows that are
|
22483 |
+
// available at the client-side
|
22484 |
+
if ( pageInfo.serverSide ) {
|
22485 |
+
row += pageInfo.start;
|
22486 |
+
}
|
22487 |
+
}
|
22488 |
+
|
22489 |
+
// Is the row on the current page? If not, we need to redraw to show the
|
22490 |
+
// page
|
22491 |
+
if ( pageInfo.length !== -1 && (row < pageInfo.start || row >= pageInfo.start+pageInfo.length) ) {
|
22492 |
+
this.s.focusDraw = true;
|
22493 |
+
this.s.waitingForDraw = true;
|
22494 |
+
|
22495 |
+
dt
|
22496 |
+
.one( 'draw', function () {
|
22497 |
+
that.s.focusDraw = false;
|
22498 |
+
that.s.waitingForDraw = false;
|
22499 |
+
that._focus( row, column, undefined, originalEvent );
|
22500 |
+
} )
|
22501 |
+
.page( Math.floor( row / pageInfo.length ) )
|
22502 |
+
.draw( false );
|
22503 |
+
|
22504 |
+
return;
|
22505 |
+
}
|
22506 |
+
|
22507 |
+
// In the available columns?
|
22508 |
+
if ( $.inArray( column, this._columns() ) === -1 ) {
|
22509 |
+
return;
|
22510 |
+
}
|
22511 |
+
|
22512 |
+
// De-normalise the server-side processing row, so we select the row
|
22513 |
+
// in its displayed position
|
22514 |
+
if ( pageInfo.serverSide ) {
|
22515 |
+
row -= pageInfo.start;
|
22516 |
+
}
|
22517 |
+
|
22518 |
+
// Get the cell from the current position - ignoring any cells which might
|
22519 |
+
// not have been rendered (therefore can't use `:eq()` selector).
|
22520 |
+
var cells = dt.cells( null, column, {search: 'applied', order: 'applied'} ).flatten();
|
22521 |
+
var cell = dt.cell( cells[ row ] );
|
22522 |
+
|
22523 |
+
if ( lastFocus ) {
|
22524 |
+
// Don't trigger a refocus on the same cell
|
22525 |
+
if ( lastFocus.node === cell.node() ) {
|
22526 |
+
this._emitEvent( 'key-refocus', [ this.s.dt, cell, originalEvent || null ] );
|
22527 |
+
return;
|
22528 |
+
}
|
22529 |
+
|
22530 |
+
// Otherwise blur the old focus
|
22531 |
+
this._blur();
|
22532 |
+
}
|
22533 |
+
|
22534 |
+
var node = $( cell.node() );
|
22535 |
+
node.addClass( this.c.className );
|
22536 |
+
|
22537 |
+
this._updateFixedColumns(column);
|
22538 |
+
|
22539 |
+
// Shift viewpoint and page to make cell visible
|
22540 |
+
if ( shift === undefined || shift === true ) {
|
22541 |
+
this._scroll( $(window), $(document.body), node, 'offset' );
|
22542 |
+
|
22543 |
+
var bodyParent = dt.table().body().parentNode;
|
22544 |
+
if ( bodyParent !== dt.table().header().parentNode ) {
|
22545 |
+
var parent = $(bodyParent.parentNode);
|
22546 |
+
|
22547 |
+
this._scroll( parent, parent, node, 'position' );
|
22548 |
+
}
|
22549 |
+
}
|
22550 |
+
|
22551 |
+
// Event and finish
|
22552 |
+
this.s.lastFocus = {
|
22553 |
+
cell: cell,
|
22554 |
+
node: cell.node(),
|
22555 |
+
relative: {
|
22556 |
+
row: dt.rows( { page: 'current' } ).indexes().indexOf( cell.index().row ),
|
22557 |
+
column: cell.index().column
|
22558 |
+
}
|
22559 |
+
};
|
22560 |
+
|
22561 |
+
this._emitEvent( 'key-focus', [ this.s.dt, cell, originalEvent || null ] );
|
22562 |
+
dt.state.save();
|
22563 |
+
},
|
22564 |
+
|
22565 |
+
|
22566 |
+
/**
|
22567 |
+
* Handle key press
|
22568 |
+
*
|
22569 |
+
* @param {object} e Event
|
22570 |
+
* @private
|
22571 |
+
*/
|
22572 |
+
_key: function ( e )
|
22573 |
+
{
|
22574 |
+
// If we are waiting for a draw to happen from another key event, then
|
22575 |
+
// do nothing for this new key press.
|
22576 |
+
if ( this.s.waitingForDraw ) {
|
22577 |
+
e.preventDefault();
|
22578 |
+
return;
|
22579 |
+
}
|
22580 |
+
|
22581 |
+
var enable = this.s.enable;
|
22582 |
+
var navEnable = enable === true || enable === 'navigation-only';
|
22583 |
+
if ( ! enable ) {
|
22584 |
+
return;
|
22585 |
+
}
|
22586 |
+
|
22587 |
+
if ( e.ctrlKey && e.keyCode === 67 ) { // c
|
22588 |
+
this._clipboardCopy();
|
22589 |
+
return;
|
22590 |
+
}
|
22591 |
+
|
22592 |
+
if ( e.keyCode === 0 || e.ctrlKey || e.metaKey || e.altKey ) {
|
22593 |
+
return;
|
22594 |
+
}
|
22595 |
+
|
22596 |
+
// If not focused, then there is no key action to take
|
22597 |
+
var lastFocus = this.s.lastFocus;
|
22598 |
+
if ( ! lastFocus ) {
|
22599 |
+
return;
|
22600 |
+
}
|
22601 |
+
|
22602 |
+
var that = this;
|
22603 |
+
var dt = this.s.dt;
|
22604 |
+
|
22605 |
+
// If we are not listening for this key, do nothing
|
22606 |
+
if ( this.c.keys && $.inArray( e.keyCode, this.c.keys ) === -1 ) {
|
22607 |
+
return;
|
22608 |
+
}
|
22609 |
+
|
22610 |
+
switch( e.keyCode ) {
|
22611 |
+
case 9: // tab
|
22612 |
+
// `enable` can be tab-only
|
22613 |
+
this._shift( e, e.shiftKey ? 'left' : 'right', true );
|
22614 |
+
break;
|
22615 |
+
|
22616 |
+
case 27: // esc
|
22617 |
+
if ( this.s.blurable && enable === true ) {
|
22618 |
+
this._blur();
|
22619 |
+
}
|
22620 |
+
break;
|
22621 |
+
|
22622 |
+
case 33: // page up (previous page)
|
22623 |
+
case 34: // page down (next page)
|
22624 |
+
if ( navEnable ) {
|
22625 |
+
e.preventDefault();
|
22626 |
+
|
22627 |
+
dt
|
22628 |
+
.page( e.keyCode === 33 ? 'previous' : 'next' )
|
22629 |
+
.draw( false );
|
22630 |
+
}
|
22631 |
+
break;
|
22632 |
+
|
22633 |
+
case 35: // end (end of current page)
|
22634 |
+
case 36: // home (start of current page)
|
22635 |
+
if ( navEnable ) {
|
22636 |
+
e.preventDefault();
|
22637 |
+
var indexes = dt.cells( {page: 'current'} ).indexes();
|
22638 |
+
var colIndexes = this._columns();
|
22639 |
+
|
22640 |
+
this._focus( dt.cell(
|
22641 |
+
indexes[ e.keyCode === 35 ? indexes.length-1 : colIndexes[0] ]
|
22642 |
+
), null, true, e );
|
22643 |
+
}
|
22644 |
+
break;
|
22645 |
+
|
22646 |
+
case 37: // left arrow
|
22647 |
+
if ( navEnable ) {
|
22648 |
+
this._shift( e, 'left' );
|
22649 |
+
}
|
22650 |
+
break;
|
22651 |
+
|
22652 |
+
case 38: // up arrow
|
22653 |
+
if ( navEnable ) {
|
22654 |
+
this._shift( e, 'up' );
|
22655 |
+
}
|
22656 |
+
break;
|
22657 |
+
|
22658 |
+
case 39: // right arrow
|
22659 |
+
if ( navEnable ) {
|
22660 |
+
this._shift( e, 'right' );
|
22661 |
+
}
|
22662 |
+
break;
|
22663 |
+
|
22664 |
+
case 40: // down arrow
|
22665 |
+
if ( navEnable ) {
|
22666 |
+
this._shift( e, 'down' );
|
22667 |
+
}
|
22668 |
+
break;
|
22669 |
+
|
22670 |
+
default:
|
22671 |
+
// Everything else - pass through only when fully enabled
|
22672 |
+
if ( enable === true ) {
|
22673 |
+
this._emitEvent( 'key', [ dt, e.keyCode, this.s.lastFocus.cell, e ] );
|
22674 |
+
}
|
22675 |
+
break;
|
22676 |
+
}
|
22677 |
+
},
|
22678 |
+
|
22679 |
+
|
22680 |
+
/**
|
22681 |
+
* Scroll a container to make a cell visible in it. This can be used for
|
22682 |
+
* both DataTables scrolling and native window scrolling.
|
22683 |
+
*
|
22684 |
+
* @param {jQuery} container Scrolling container
|
22685 |
+
* @param {jQuery} scroller Item being scrolled
|
22686 |
+
* @param {jQuery} cell Cell in the scroller
|
22687 |
+
* @param {string} posOff `position` or `offset` - which to use for the
|
22688 |
+
* calculation. `offset` for the document, otherwise `position`
|
22689 |
+
* @private
|
22690 |
+
*/
|
22691 |
+
_scroll: function ( container, scroller, cell, posOff )
|
22692 |
+
{
|
22693 |
+
var offset = cell[posOff]();
|
22694 |
+
var height = cell.outerHeight();
|
22695 |
+
var width = cell.outerWidth();
|
22696 |
+
|
22697 |
+
var scrollTop = scroller.scrollTop();
|
22698 |
+
var scrollLeft = scroller.scrollLeft();
|
22699 |
+
var containerHeight = container.height();
|
22700 |
+
var containerWidth = container.width();
|
22701 |
+
|
22702 |
+
// If Scroller is being used, the table can be `position: absolute` and that
|
22703 |
+
// needs to be taken account of in the offset. If no Scroller, this will be 0
|
22704 |
+
if ( posOff === 'position' ) {
|
22705 |
+
offset.top += parseInt( cell.closest('table').css('top'), 10 );
|
22706 |
+
}
|
22707 |
+
|
22708 |
+
// Top correction
|
22709 |
+
if ( offset.top < scrollTop ) {
|
22710 |
+
scroller.scrollTop( offset.top );
|
22711 |
+
}
|
22712 |
+
|
22713 |
+
// Left correction
|
22714 |
+
if ( offset.left < scrollLeft ) {
|
22715 |
+
scroller.scrollLeft( offset.left );
|
22716 |
+
}
|
22717 |
+
|
22718 |
+
// Bottom correction
|
22719 |
+
if ( offset.top + height > scrollTop + containerHeight && height < containerHeight ) {
|
22720 |
+
scroller.scrollTop( offset.top + height - containerHeight );
|
22721 |
+
}
|
22722 |
+
|
22723 |
+
// Right correction
|
22724 |
+
if ( offset.left + width > scrollLeft + containerWidth && width < containerWidth ) {
|
22725 |
+
scroller.scrollLeft( offset.left + width - containerWidth );
|
22726 |
+
}
|
22727 |
+
},
|
22728 |
+
|
22729 |
+
|
22730 |
+
/**
|
22731 |
+
* Calculate a single offset movement in the table - up, down, left and
|
22732 |
+
* right and then perform the focus if possible
|
22733 |
+
*
|
22734 |
+
* @param {object} e Event object
|
22735 |
+
* @param {string} direction Movement direction
|
22736 |
+
* @param {boolean} keyBlurable `true` if the key press can result in the
|
22737 |
+
* table being blurred. This is so arrow keys won't blur the table, but
|
22738 |
+
* tab will.
|
22739 |
+
* @private
|
22740 |
+
*/
|
22741 |
+
_shift: function ( e, direction, keyBlurable )
|
22742 |
+
{
|
22743 |
+
var that = this;
|
22744 |
+
var dt = this.s.dt;
|
22745 |
+
var pageInfo = dt.page.info();
|
22746 |
+
var rows = pageInfo.recordsDisplay;
|
22747 |
+
var currentCell = this.s.lastFocus.cell;
|
22748 |
+
var columns = this._columns();
|
22749 |
+
|
22750 |
+
if ( ! currentCell ) {
|
22751 |
+
return;
|
22752 |
+
}
|
22753 |
+
|
22754 |
+
var currRow = dt
|
22755 |
+
.rows( { filter: 'applied', order: 'applied' } )
|
22756 |
+
.indexes()
|
22757 |
+
.indexOf( currentCell.index().row );
|
22758 |
+
|
22759 |
+
// When server-side processing, `rows().indexes()` only gives the rows
|
22760 |
+
// that are available at the client-side, so we need to normalise the
|
22761 |
+
// row's current position by the display start point
|
22762 |
+
if ( pageInfo.serverSide ) {
|
22763 |
+
currRow += pageInfo.start;
|
22764 |
+
}
|
22765 |
+
|
22766 |
+
var currCol = dt
|
22767 |
+
.columns( columns )
|
22768 |
+
.indexes()
|
22769 |
+
.indexOf( currentCell.index().column );
|
22770 |
+
|
22771 |
+
var
|
22772 |
+
row = currRow,
|
22773 |
+
column = columns[ currCol ]; // row is the display, column is an index
|
22774 |
+
|
22775 |
+
if ( direction === 'right' ) {
|
22776 |
+
if ( currCol >= columns.length - 1 ) {
|
22777 |
+
row++;
|
22778 |
+
column = columns[0];
|
22779 |
+
}
|
22780 |
+
else {
|
22781 |
+
column = columns[ currCol+1 ];
|
22782 |
+
}
|
22783 |
+
}
|
22784 |
+
else if ( direction === 'left' ) {
|
22785 |
+
if ( currCol === 0 ) {
|
22786 |
+
row--;
|
22787 |
+
column = columns[ columns.length - 1 ];
|
22788 |
+
}
|
22789 |
+
else {
|
22790 |
+
column = columns[ currCol-1 ];
|
22791 |
+
}
|
22792 |
+
}
|
22793 |
+
else if ( direction === 'up' ) {
|
22794 |
+
row--;
|
22795 |
+
}
|
22796 |
+
else if ( direction === 'down' ) {
|
22797 |
+
row++;
|
22798 |
+
}
|
22799 |
+
|
22800 |
+
if ( row >= 0 && row < rows && $.inArray( column, columns ) !== -1
|
22801 |
+
) {
|
22802 |
+
e.preventDefault();
|
22803 |
+
|
22804 |
+
this._focus( row, column, true, e );
|
22805 |
+
}
|
22806 |
+
else if ( ! keyBlurable || ! this.c.blurable ) {
|
22807 |
+
// No new focus, but if the table isn't blurable, then don't loose
|
22808 |
+
// focus
|
22809 |
+
e.preventDefault();
|
22810 |
+
}
|
22811 |
+
else {
|
22812 |
+
this._blur();
|
22813 |
+
}
|
22814 |
+
},
|
22815 |
+
|
22816 |
+
|
22817 |
+
/**
|
22818 |
+
* Create a hidden input element that can receive focus on behalf of the
|
22819 |
+
* table
|
22820 |
+
*
|
22821 |
+
* @private
|
22822 |
+
*/
|
22823 |
+
_tabInput: function ()
|
22824 |
+
{
|
22825 |
+
var that = this;
|
22826 |
+
var dt = this.s.dt;
|
22827 |
+
var tabIndex = this.c.tabIndex !== null ?
|
22828 |
+
this.c.tabIndex :
|
22829 |
+
dt.settings()[0].iTabIndex;
|
22830 |
+
|
22831 |
+
if ( tabIndex == -1 ) {
|
22832 |
+
return;
|
22833 |
+
}
|
22834 |
+
|
22835 |
+
var div = $('<div><input type="text" tabindex="'+tabIndex+'"/></div>')
|
22836 |
+
.css( {
|
22837 |
+
position: 'absolute',
|
22838 |
+
height: 1,
|
22839 |
+
width: 0,
|
22840 |
+
overflow: 'hidden'
|
22841 |
+
} )
|
22842 |
+
.insertBefore( dt.table().node() );
|
22843 |
+
|
22844 |
+
div.children().on( 'focus', function (e) {
|
22845 |
+
if ( dt.cell(':eq(0)', {page: 'current'}).any() ) {
|
22846 |
+
that._focus( dt.cell(':eq(0)', '0:visible', {page: 'current'}), null, true, e );
|
22847 |
+
}
|
22848 |
+
} );
|
22849 |
+
},
|
22850 |
+
|
22851 |
+
/**
|
22852 |
+
* Update fixed columns if they are enabled and if the cell we are
|
22853 |
+
* focusing is inside a fixed column
|
22854 |
+
* @param {integer} column Index of the column being changed
|
22855 |
+
* @private
|
22856 |
+
*/
|
22857 |
+
_updateFixedColumns: function( column )
|
22858 |
+
{
|
22859 |
+
var dt = this.s.dt;
|
22860 |
+
var settings = dt.settings()[0];
|
22861 |
+
|
22862 |
+
if ( settings._oFixedColumns ) {
|
22863 |
+
var leftCols = settings._oFixedColumns.s.iLeftColumns;
|
22864 |
+
var rightCols = settings.aoColumns.length - settings._oFixedColumns.s.iRightColumns;
|
22865 |
+
|
22866 |
+
if (column < leftCols || column >= rightCols) {
|
22867 |
+
dt.fixedColumns().update();
|
22868 |
+
}
|
22869 |
+
}
|
22870 |
+
}
|
22871 |
+
} );
|
22872 |
+
|
22873 |
+
|
22874 |
+
/**
|
22875 |
+
* KeyTable default settings for initialisation
|
22876 |
+
*
|
22877 |
+
* @namespace
|
22878 |
+
* @name KeyTable.defaults
|
22879 |
+
* @static
|
22880 |
+
*/
|
22881 |
+
KeyTable.defaults = {
|
22882 |
+
/**
|
22883 |
+
* Can focus be removed from the table
|
22884 |
+
* @type {Boolean}
|
22885 |
+
*/
|
22886 |
+
blurable: true,
|
22887 |
+
|
22888 |
+
/**
|
22889 |
+
* Class to give to the focused cell
|
22890 |
+
* @type {String}
|
22891 |
+
*/
|
22892 |
+
className: 'focus',
|
22893 |
+
|
22894 |
+
/**
|
22895 |
+
* Columns that can be focused. This is automatically merged with the
|
22896 |
+
* visible columns as only visible columns can gain focus.
|
22897 |
+
* @type {String}
|
22898 |
+
*/
|
22899 |
+
columns: '', // all
|
22900 |
+
|
22901 |
+
/**
|
22902 |
+
* Editor instance to automatically perform Excel like navigation
|
22903 |
+
* @type {Editor}
|
22904 |
+
*/
|
22905 |
+
editor: null,
|
22906 |
+
|
22907 |
+
/**
|
22908 |
+
* Option that defines what KeyTable's behaviour will be when used with
|
22909 |
+
* Editor's inline editing. Can be `navigation-only` or `tab-only`.
|
22910 |
+
* @type {String}
|
22911 |
+
*/
|
22912 |
+
editorKeys: 'navigation-only',
|
22913 |
+
|
22914 |
+
/**
|
22915 |
+
* Set if Editor should automatically select the text in the input
|
22916 |
+
* @type {Boolean}
|
22917 |
+
*/
|
22918 |
+
editAutoSelect: true,
|
22919 |
+
|
22920 |
+
/**
|
22921 |
+
* Control if editing should be activated immediately upon focus
|
22922 |
+
* @type {Boolean}
|
22923 |
+
*/
|
22924 |
+
editOnFocus: false,
|
22925 |
+
|
22926 |
+
/**
|
22927 |
+
* Select a cell to automatically select on start up. `null` for no
|
22928 |
+
* automatic selection
|
22929 |
+
* @type {cell-selector}
|
22930 |
+
*/
|
22931 |
+
focus: null,
|
22932 |
+
|
22933 |
+
/**
|
22934 |
+
* Array of keys to listen for
|
22935 |
+
* @type {null|array}
|
22936 |
+
*/
|
22937 |
+
keys: null,
|
22938 |
+
|
22939 |
+
/**
|
22940 |
+
* Tab index for where the table should sit in the document's tab flow
|
22941 |
+
* @type {integer|null}
|
22942 |
+
*/
|
22943 |
+
tabIndex: null
|
22944 |
+
};
|
22945 |
+
|
22946 |
+
|
22947 |
+
|
22948 |
+
KeyTable.version = "2.3.2";
|
22949 |
+
|
22950 |
+
|
22951 |
+
$.fn.dataTable.KeyTable = KeyTable;
|
22952 |
+
$.fn.DataTable.KeyTable = KeyTable;
|
22953 |
+
|
22954 |
+
|
22955 |
+
DataTable.Api.register( 'cell.blur()', function () {
|
22956 |
+
return this.iterator( 'table', function (ctx) {
|
22957 |
+
if ( ctx.keytable ) {
|
22958 |
+
ctx.keytable.blur();
|
22959 |
+
}
|
22960 |
+
} );
|
22961 |
+
} );
|
22962 |
+
|
22963 |
+
DataTable.Api.register( 'cell().focus()', function () {
|
22964 |
+
return this.iterator( 'cell', function (ctx, row, column) {
|
22965 |
+
if ( ctx.keytable ) {
|
22966 |
+
ctx.keytable.focus( row, column );
|
22967 |
+
}
|
22968 |
+
} );
|
22969 |
+
} );
|
22970 |
+
|
22971 |
+
DataTable.Api.register( 'keys.disable()', function () {
|
22972 |
+
return this.iterator( 'table', function (ctx) {
|
22973 |
+
if ( ctx.keytable ) {
|
22974 |
+
ctx.keytable.enable( false );
|
22975 |
+
}
|
22976 |
+
} );
|
22977 |
+
} );
|
22978 |
+
|
22979 |
+
DataTable.Api.register( 'keys.enable()', function ( opts ) {
|
22980 |
+
return this.iterator( 'table', function (ctx) {
|
22981 |
+
if ( ctx.keytable ) {
|
22982 |
+
ctx.keytable.enable( opts === undefined ? true : opts );
|
22983 |
+
}
|
22984 |
+
} );
|
22985 |
+
} );
|
22986 |
+
|
22987 |
+
// Cell selector
|
22988 |
+
DataTable.ext.selector.cell.push( function ( settings, opts, cells ) {
|
22989 |
+
var focused = opts.focused;
|
22990 |
+
var kt = settings.keytable;
|
22991 |
+
var out = [];
|
22992 |
+
|
22993 |
+
if ( ! kt || focused === undefined ) {
|
22994 |
+
return cells;
|
22995 |
+
}
|
22996 |
+
|
22997 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
22998 |
+
if ( (focused === true && kt.focused( cells[i] ) ) ||
|
22999 |
+
(focused === false && ! kt.focused( cells[i] ) )
|
23000 |
+
) {
|
23001 |
+
out.push( cells[i] );
|
23002 |
+
}
|
23003 |
+
}
|
23004 |
+
|
23005 |
+
return out;
|
23006 |
+
} );
|
23007 |
+
|
23008 |
+
|
23009 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
23010 |
+
// events so we can automatically initialise
|
23011 |
+
$(document).on( 'preInit.dt.dtk', function (e, settings, json) {
|
23012 |
+
if ( e.namespace !== 'dt' ) {
|
23013 |
+
return;
|
23014 |
+
}
|
23015 |
+
|
23016 |
+
var init = settings.oInit.keys;
|
23017 |
+
var defaults = DataTable.defaults.keys;
|
23018 |
+
|
23019 |
+
if ( init || defaults ) {
|
23020 |
+
var opts = $.extend( {}, defaults, init );
|
23021 |
+
|
23022 |
+
if ( init !== false ) {
|
23023 |
+
new KeyTable( settings, opts );
|
23024 |
+
}
|
23025 |
+
}
|
23026 |
+
} );
|
23027 |
+
|
23028 |
+
|
23029 |
+
return KeyTable;
|
23030 |
+
}));
|
23031 |
+
|
23032 |
+
|
23033 |
+
/*! Responsive 2.2.1
|
23034 |
+
* 2014-2017 SpryMedia Ltd - datatables.net/license
|
23035 |
+
*/
|
23036 |
+
|
23037 |
+
/**
|
23038 |
+
* @summary Responsive
|
23039 |
+
* @description Responsive tables plug-in for DataTables
|
23040 |
+
* @version 2.2.1
|
23041 |
+
* @file dataTables.responsive.js
|
23042 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
23043 |
+
* @contact www.sprymedia.co.uk/contact
|
23044 |
+
* @copyright Copyright 2014-2017 SpryMedia Ltd.
|
23045 |
+
*
|
23046 |
+
* This source file is free software, available under the following license:
|
23047 |
+
* MIT license - http://datatables.net/license/mit
|
23048 |
+
*
|
23049 |
+
* This source file is distributed in the hope that it will be useful, but
|
23050 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
23051 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
23052 |
+
*
|
23053 |
+
* For details please refer to: http://www.datatables.net
|
23054 |
+
*/
|
23055 |
+
(function( factory ){
|
23056 |
+
if ( typeof define === 'function' && define.amd ) {
|
23057 |
+
// AMD
|
23058 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
23059 |
+
return factory( $, window, document );
|
23060 |
+
} );
|
23061 |
+
}
|
23062 |
+
else if ( typeof exports === 'object' ) {
|
23063 |
+
// CommonJS
|
23064 |
+
module.exports = function (root, $) {
|
23065 |
+
if ( ! root ) {
|
23066 |
+
root = window;
|
23067 |
+
}
|
23068 |
+
|
23069 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
23070 |
+
$ = require('datatables.net')(root, $).$;
|
23071 |
+
}
|
23072 |
+
|
23073 |
+
return factory( $, root, root.document );
|
23074 |
+
};
|
23075 |
+
}
|
23076 |
+
else {
|
23077 |
+
// Browser
|
23078 |
+
factory( jQuery, window, document );
|
23079 |
+
}
|
23080 |
+
}(function( $, window, document, undefined ) {
|
23081 |
+
'use strict';
|
23082 |
+
var DataTable = $.fn.dataTable;
|
23083 |
+
|
23084 |
+
|
23085 |
+
/**
|
23086 |
+
* Responsive is a plug-in for the DataTables library that makes use of
|
23087 |
+
* DataTables' ability to change the visibility of columns, changing the
|
23088 |
+
* visibility of columns so the displayed columns fit into the table container.
|
23089 |
+
* The end result is that complex tables will be dynamically adjusted to fit
|
23090 |
+
* into the viewport, be it on a desktop, tablet or mobile browser.
|
23091 |
+
*
|
23092 |
+
* Responsive for DataTables has two modes of operation, which can used
|
23093 |
+
* individually or combined:
|
23094 |
+
*
|
23095 |
+
* * Class name based control - columns assigned class names that match the
|
23096 |
+
* breakpoint logic can be shown / hidden as required for each breakpoint.
|
23097 |
+
* * Automatic control - columns are automatically hidden when there is no
|
23098 |
+
* room left to display them. Columns removed from the right.
|
23099 |
+
*
|
23100 |
+
* In additional to column visibility control, Responsive also has built into
|
23101 |
+
* options to use DataTables' child row display to show / hide the information
|
23102 |
+
* from the table that has been hidden. There are also two modes of operation
|
23103 |
+
* for this child row display:
|
23104 |
+
*
|
23105 |
+
* * Inline - when the control element that the user can use to show / hide
|
23106 |
+
* child rows is displayed inside the first column of the table.
|
23107 |
+
* * Column - where a whole column is dedicated to be the show / hide control.
|
23108 |
+
*
|
23109 |
+
* Initialisation of Responsive is performed by:
|
23110 |
+
*
|
23111 |
+
* * Adding the class `responsive` or `dt-responsive` to the table. In this case
|
23112 |
+
* Responsive will automatically be initialised with the default configuration
|
23113 |
+
* options when the DataTable is created.
|
23114 |
+
* * Using the `responsive` option in the DataTables configuration options. This
|
23115 |
+
* can also be used to specify the configuration options, or simply set to
|
23116 |
+
* `true` to use the defaults.
|
23117 |
+
*
|
23118 |
+
* @class
|
23119 |
+
* @param {object} settings DataTables settings object for the host table
|
23120 |
+
* @param {object} [opts] Configuration options
|
23121 |
+
* @requires jQuery 1.7+
|
23122 |
+
* @requires DataTables 1.10.3+
|
23123 |
+
*
|
23124 |
+
* @example
|
23125 |
+
* $('#example').DataTable( {
|
23126 |
+
* responsive: true
|
23127 |
+
* } );
|
23128 |
+
* } );
|
23129 |
+
*/
|
23130 |
+
var Responsive = function ( settings, opts ) {
|
23131 |
+
// Sanity check that we are using DataTables 1.10 or newer
|
23132 |
+
if ( ! DataTable.versionCheck || ! DataTable.versionCheck( '1.10.10' ) ) {
|
23133 |
+
throw 'DataTables Responsive requires DataTables 1.10.10 or newer';
|
23134 |
+
}
|
23135 |
+
|
23136 |
+
this.s = {
|
23137 |
+
dt: new DataTable.Api( settings ),
|
23138 |
+
columns: [],
|
23139 |
+
current: []
|
23140 |
+
};
|
23141 |
+
|
23142 |
+
// Check if responsive has already been initialised on this table
|
23143 |
+
if ( this.s.dt.settings()[0].responsive ) {
|
23144 |
+
return;
|
23145 |
+
}
|
23146 |
+
|
23147 |
+
// details is an object, but for simplicity the user can give it as a string
|
23148 |
+
// or a boolean
|
23149 |
+
if ( opts && typeof opts.details === 'string' ) {
|
23150 |
+
opts.details = { type: opts.details };
|
23151 |
+
}
|
23152 |
+
else if ( opts && opts.details === false ) {
|
23153 |
+
opts.details = { type: false };
|
23154 |
+
}
|
23155 |
+
else if ( opts && opts.details === true ) {
|
23156 |
+
opts.details = { type: 'inline' };
|
23157 |
+
}
|
23158 |
+
|
23159 |
+
this.c = $.extend( true, {}, Responsive.defaults, DataTable.defaults.responsive, opts );
|
23160 |
+
settings.responsive = this;
|
23161 |
+
this._constructor();
|
23162 |
+
};
|
23163 |
+
|
23164 |
+
$.extend( Responsive.prototype, {
|
23165 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
23166 |
+
* Constructor
|
23167 |
+
*/
|
23168 |
+
|
23169 |
+
/**
|
23170 |
+
* Initialise the Responsive instance
|
23171 |
+
*
|
23172 |
+
* @private
|
23173 |
+
*/
|
23174 |
+
_constructor: function ()
|
23175 |
+
{
|
23176 |
+
var that = this;
|
23177 |
+
var dt = this.s.dt;
|
23178 |
+
var dtPrivateSettings = dt.settings()[0];
|
23179 |
+
var oldWindowWidth = $(window).width();
|
23180 |
+
|
23181 |
+
dt.settings()[0]._responsive = this;
|
23182 |
+
|
23183 |
+
// Use DataTables' throttle function to avoid processor thrashing on
|
23184 |
+
// resize
|
23185 |
+
$(window).on( 'resize.dtr orientationchange.dtr', DataTable.util.throttle( function () {
|
23186 |
+
// iOS has a bug whereby resize can fire when only scrolling
|
23187 |
+
// See: http://stackoverflow.com/questions/8898412
|
23188 |
+
var width = $(window).width();
|
23189 |
+
|
23190 |
+
if ( width !== oldWindowWidth ) {
|
23191 |
+
that._resize();
|
23192 |
+
oldWindowWidth = width;
|
23193 |
+
}
|
23194 |
+
} ) );
|
23195 |
+
|
23196 |
+
// DataTables doesn't currently trigger an event when a row is added, so
|
23197 |
+
// we need to hook into its private API to enforce the hidden rows when
|
23198 |
+
// new data is added
|
23199 |
+
dtPrivateSettings.oApi._fnCallbackReg( dtPrivateSettings, 'aoRowCreatedCallback', function (tr, data, idx) {
|
23200 |
+
if ( $.inArray( false, that.s.current ) !== -1 ) {
|
23201 |
+
$('>td, >th', tr).each( function ( i ) {
|
23202 |
+
var idx = dt.column.index( 'toData', i );
|
23203 |
+
|
23204 |
+
if ( that.s.current[idx] === false ) {
|
23205 |
+
$(this).css('display', 'none');
|
23206 |
+
}
|
23207 |
+
} );
|
23208 |
+
}
|
23209 |
+
} );
|
23210 |
+
|
23211 |
+
// Destroy event handler
|
23212 |
+
dt.on( 'destroy.dtr', function () {
|
23213 |
+
dt.off( '.dtr' );
|
23214 |
+
$( dt.table().body() ).off( '.dtr' );
|
23215 |
+
$(window).off( 'resize.dtr orientationchange.dtr' );
|
23216 |
+
|
23217 |
+
// Restore the columns that we've hidden
|
23218 |
+
$.each( that.s.current, function ( i, val ) {
|
23219 |
+
if ( val === false ) {
|
23220 |
+
that._setColumnVis( i, true );
|
23221 |
+
}
|
23222 |
+
} );
|
23223 |
+
} );
|
23224 |
+
|
23225 |
+
// Reorder the breakpoints array here in case they have been added out
|
23226 |
+
// of order
|
23227 |
+
this.c.breakpoints.sort( function (a, b) {
|
23228 |
+
return a.width < b.width ? 1 :
|
23229 |
+
a.width > b.width ? -1 : 0;
|
23230 |
+
} );
|
23231 |
+
|
23232 |
+
this._classLogic();
|
23233 |
+
this._resizeAuto();
|
23234 |
+
|
23235 |
+
// Details handler
|
23236 |
+
var details = this.c.details;
|
23237 |
+
|
23238 |
+
if ( details.type !== false ) {
|
23239 |
+
that._detailsInit();
|
23240 |
+
|
23241 |
+
// DataTables will trigger this event on every column it shows and
|
23242 |
+
// hides individually
|
23243 |
+
dt.on( 'column-visibility.dtr', function (e, ctx, col, vis, recalc) {
|
23244 |
+
if ( recalc ) {
|
23245 |
+
that._classLogic();
|
23246 |
+
that._resizeAuto();
|
23247 |
+
that._resize();
|
23248 |
+
}
|
23249 |
+
} );
|
23250 |
+
|
23251 |
+
// Redraw the details box on each draw which will happen if the data
|
23252 |
+
// has changed. This is used until DataTables implements a native
|
23253 |
+
// `updated` event for rows
|
23254 |
+
dt.on( 'draw.dtr', function () {
|
23255 |
+
that._redrawChildren();
|
23256 |
+
} );
|
23257 |
+
|
23258 |
+
$(dt.table().node()).addClass( 'dtr-'+details.type );
|
23259 |
+
}
|
23260 |
+
|
23261 |
+
dt.on( 'column-reorder.dtr', function (e, settings, details) {
|
23262 |
+
that._classLogic();
|
23263 |
+
that._resizeAuto();
|
23264 |
+
that._resize();
|
23265 |
+
} );
|
23266 |
+
|
23267 |
+
// Change in column sizes means we need to calc
|
23268 |
+
dt.on( 'column-sizing.dtr', function () {
|
23269 |
+
that._resizeAuto();
|
23270 |
+
that._resize();
|
23271 |
+
});
|
23272 |
+
|
23273 |
+
// On Ajax reload we want to reopen any child rows which are displayed
|
23274 |
+
// by responsive
|
23275 |
+
dt.on( 'preXhr.dtr', function () {
|
23276 |
+
var rowIds = [];
|
23277 |
+
dt.rows().every( function () {
|
23278 |
+
if ( this.child.isShown() ) {
|
23279 |
+
rowIds.push( this.id(true) );
|
23280 |
+
}
|
23281 |
+
} );
|
23282 |
+
|
23283 |
+
dt.one( 'draw.dtr', function () {
|
23284 |
+
that._resizeAuto();
|
23285 |
+
that._resize();
|
23286 |
+
|
23287 |
+
dt.rows( rowIds ).every( function () {
|
23288 |
+
that._detailsDisplay( this, false );
|
23289 |
+
} );
|
23290 |
+
} );
|
23291 |
+
});
|
23292 |
+
|
23293 |
+
dt.on( 'init.dtr', function (e, settings, details) {
|
23294 |
+
that._resizeAuto();
|
23295 |
+
that._resize();
|
23296 |
+
|
23297 |
+
// If columns were hidden, then DataTables needs to adjust the
|
23298 |
+
// column sizing
|
23299 |
+
if ( $.inArray( false, that.s.current ) ) {
|
23300 |
+
dt.columns.adjust();
|
23301 |
+
}
|
23302 |
+
} );
|
23303 |
+
|
23304 |
+
// First pass - draw the table for the current viewport size
|
23305 |
+
this._resize();
|
23306 |
+
},
|
23307 |
+
|
23308 |
+
|
23309 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
23310 |
+
* Private methods
|
23311 |
+
*/
|
23312 |
+
|
23313 |
+
/**
|
23314 |
+
* Calculate the visibility for the columns in a table for a given
|
23315 |
+
* breakpoint. The result is pre-determined based on the class logic if
|
23316 |
+
* class names are used to control all columns, but the width of the table
|
23317 |
+
* is also used if there are columns which are to be automatically shown
|
23318 |
+
* and hidden.
|
23319 |
+
*
|
23320 |
+
* @param {string} breakpoint Breakpoint name to use for the calculation
|
23321 |
+
* @return {array} Array of boolean values initiating the visibility of each
|
23322 |
+
* column.
|
23323 |
+
* @private
|
23324 |
+
*/
|
23325 |
+
_columnsVisiblity: function ( breakpoint )
|
23326 |
+
{
|
23327 |
+
var dt = this.s.dt;
|
23328 |
+
var columns = this.s.columns;
|
23329 |
+
var i, ien;
|
23330 |
+
|
23331 |
+
// Create an array that defines the column ordering based first on the
|
23332 |
+
// column's priority, and secondly the column index. This allows the
|
23333 |
+
// columns to be removed from the right if the priority matches
|
23334 |
+
var order = columns
|
23335 |
+
.map( function ( col, idx ) {
|
23336 |
+
return {
|
23337 |
+
columnIdx: idx,
|
23338 |
+
priority: col.priority
|
23339 |
+
};
|
23340 |
+
} )
|
23341 |
+
.sort( function ( a, b ) {
|
23342 |
+
if ( a.priority !== b.priority ) {
|
23343 |
+
return a.priority - b.priority;
|
23344 |
+
}
|
23345 |
+
return a.columnIdx - b.columnIdx;
|
23346 |
+
} );
|
23347 |
+
|
23348 |
+
// Class logic - determine which columns are in this breakpoint based
|
23349 |
+
// on the classes. If no class control (i.e. `auto`) then `-` is used
|
23350 |
+
// to indicate this to the rest of the function
|
23351 |
+
var display = $.map( columns, function ( col ) {
|
23352 |
+
return col.auto && col.minWidth === null ?
|
23353 |
+
false :
|
23354 |
+
col.auto === true ?
|
23355 |
+
'-' :
|
23356 |
+
$.inArray( breakpoint, col.includeIn ) !== -1;
|
23357 |
+
} );
|
23358 |
+
|
23359 |
+
// Auto column control - first pass: how much width is taken by the
|
23360 |
+
// ones that must be included from the non-auto columns
|
23361 |
+
var requiredWidth = 0;
|
23362 |
+
for ( i=0, ien=display.length ; i<ien ; i++ ) {
|
23363 |
+
if ( display[i] === true ) {
|
23364 |
+
requiredWidth += columns[i].minWidth;
|
23365 |
+
}
|
23366 |
+
}
|
23367 |
+
|
23368 |
+
// Second pass, use up any remaining width for other columns. For
|
23369 |
+
// scrolling tables we need to subtract the width of the scrollbar. It
|
23370 |
+
// may not be requires which makes this sub-optimal, but it would
|
23371 |
+
// require another full redraw to make complete use of those extra few
|
23372 |
+
// pixels
|
23373 |
+
var scrolling = dt.settings()[0].oScroll;
|
23374 |
+
var bar = scrolling.sY || scrolling.sX ? scrolling.iBarWidth : 0;
|
23375 |
+
var widthAvailable = dt.table().container().offsetWidth - bar;
|
23376 |
+
var usedWidth = widthAvailable - requiredWidth;
|
23377 |
+
|
23378 |
+
// Control column needs to always be included. This makes it sub-
|
23379 |
+
// optimal in terms of using the available with, but to stop layout
|
23380 |
+
// thrashing or overflow. Also we need to account for the control column
|
23381 |
+
// width first so we know how much width is available for the other
|
23382 |
+
// columns, since the control column might not be the first one shown
|
23383 |
+
for ( i=0, ien=display.length ; i<ien ; i++ ) {
|
23384 |
+
if ( columns[i].control ) {
|
23385 |
+
usedWidth -= columns[i].minWidth;
|
23386 |
+
}
|
23387 |
+
}
|
23388 |
+
|
23389 |
+
// Allow columns to be shown (counting by priority and then right to
|
23390 |
+
// left) until we run out of room
|
23391 |
+
var empty = false;
|
23392 |
+
for ( i=0, ien=order.length ; i<ien ; i++ ) {
|
23393 |
+
var colIdx = order[i].columnIdx;
|
23394 |
+
|
23395 |
+
if ( display[colIdx] === '-' && ! columns[colIdx].control && columns[colIdx].minWidth ) {
|
23396 |
+
// Once we've found a column that won't fit we don't let any
|
23397 |
+
// others display either, or columns might disappear in the
|
23398 |
+
// middle of the table
|
23399 |
+
if ( empty || usedWidth - columns[colIdx].minWidth < 0 ) {
|
23400 |
+
empty = true;
|
23401 |
+
display[colIdx] = false;
|
23402 |
+
}
|
23403 |
+
else {
|
23404 |
+
display[colIdx] = true;
|
23405 |
+
}
|
23406 |
+
|
23407 |
+
usedWidth -= columns[colIdx].minWidth;
|
23408 |
+
}
|
23409 |
+
}
|
23410 |
+
|
23411 |
+
// Determine if the 'control' column should be shown (if there is one).
|
23412 |
+
// This is the case when there is a hidden column (that is not the
|
23413 |
+
// control column). The two loops look inefficient here, but they are
|
23414 |
+
// trivial and will fly through. We need to know the outcome from the
|
23415 |
+
// first , before the action in the second can be taken
|
23416 |
+
var showControl = false;
|
23417 |
+
|
23418 |
+
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
23419 |
+
if ( ! columns[i].control && ! columns[i].never && ! display[i] ) {
|
23420 |
+
showControl = true;
|
23421 |
+
break;
|
23422 |
+
}
|
23423 |
+
}
|
23424 |
+
|
23425 |
+
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
23426 |
+
if ( columns[i].control ) {
|
23427 |
+
display[i] = showControl;
|
23428 |
+
}
|
23429 |
+
}
|
23430 |
+
|
23431 |
+
// Finally we need to make sure that there is at least one column that
|
23432 |
+
// is visible
|
23433 |
+
if ( $.inArray( true, display ) === -1 ) {
|
23434 |
+
display[0] = true;
|
23435 |
+
}
|
23436 |
+
|
23437 |
+
return display;
|
23438 |
+
},
|
23439 |
+
|
23440 |
+
|
23441 |
+
/**
|
23442 |
+
* Create the internal `columns` array with information about the columns
|
23443 |
+
* for the table. This includes determining which breakpoints the column
|
23444 |
+
* will appear in, based upon class names in the column, which makes up the
|
23445 |
+
* vast majority of this method.
|
23446 |
+
*
|
23447 |
+
* @private
|
23448 |
+
*/
|
23449 |
+
_classLogic: function ()
|
23450 |
+
{
|
23451 |
+
var that = this;
|
23452 |
+
var calc = {};
|
23453 |
+
var breakpoints = this.c.breakpoints;
|
23454 |
+
var dt = this.s.dt;
|
23455 |
+
var columns = dt.columns().eq(0).map( function (i) {
|
23456 |
+
var column = this.column(i);
|
23457 |
+
var className = column.header().className;
|
23458 |
+
var priority = dt.settings()[0].aoColumns[i].responsivePriority;
|
23459 |
+
|
23460 |
+
if ( priority === undefined ) {
|
23461 |
+
var dataPriority = $(column.header()).data('priority');
|
23462 |
+
|
23463 |
+
priority = dataPriority !== undefined ?
|
23464 |
+
dataPriority * 1 :
|
23465 |
+
10000;
|
23466 |
+
}
|
23467 |
+
|
23468 |
+
return {
|
23469 |
+
className: className,
|
23470 |
+
includeIn: [],
|
23471 |
+
auto: false,
|
23472 |
+
control: false,
|
23473 |
+
never: className.match(/\bnever\b/) ? true : false,
|
23474 |
+
priority: priority
|
23475 |
+
};
|
23476 |
+
} );
|
23477 |
+
|
23478 |
+
// Simply add a breakpoint to `includeIn` array, ensuring that there are
|
23479 |
+
// no duplicates
|
23480 |
+
var add = function ( colIdx, name ) {
|
23481 |
+
var includeIn = columns[ colIdx ].includeIn;
|
23482 |
+
|
23483 |
+
if ( $.inArray( name, includeIn ) === -1 ) {
|
23484 |
+
includeIn.push( name );
|
23485 |
+
}
|
23486 |
+
};
|
23487 |
+
|
23488 |
+
var column = function ( colIdx, name, operator, matched ) {
|
23489 |
+
var size, i, ien;
|
23490 |
+
|
23491 |
+
if ( ! operator ) {
|
23492 |
+
columns[ colIdx ].includeIn.push( name );
|
23493 |
+
}
|
23494 |
+
else if ( operator === 'max-' ) {
|
23495 |
+
// Add this breakpoint and all smaller
|
23496 |
+
size = that._find( name ).width;
|
23497 |
+
|
23498 |
+
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
23499 |
+
if ( breakpoints[i].width <= size ) {
|
23500 |
+
add( colIdx, breakpoints[i].name );
|
23501 |
+
}
|
23502 |
+
}
|
23503 |
+
}
|
23504 |
+
else if ( operator === 'min-' ) {
|
23505 |
+
// Add this breakpoint and all larger
|
23506 |
+
size = that._find( name ).width;
|
23507 |
+
|
23508 |
+
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
23509 |
+
if ( breakpoints[i].width >= size ) {
|
23510 |
+
add( colIdx, breakpoints[i].name );
|
23511 |
+
}
|
23512 |
+
}
|
23513 |
+
}
|
23514 |
+
else if ( operator === 'not-' ) {
|
23515 |
+
// Add all but this breakpoint
|
23516 |
+
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
23517 |
+
if ( breakpoints[i].name.indexOf( matched ) === -1 ) {
|
23518 |
+
add( colIdx, breakpoints[i].name );
|
23519 |
+
}
|
23520 |
+
}
|
23521 |
+
}
|
23522 |
+
};
|
23523 |
+
|
23524 |
+
// Loop over each column and determine if it has a responsive control
|
23525 |
+
// class
|
23526 |
+
columns.each( function ( col, i ) {
|
23527 |
+
var classNames = col.className.split(' ');
|
23528 |
+
var hasClass = false;
|
23529 |
+
|
23530 |
+
// Split the class name up so multiple rules can be applied if needed
|
23531 |
+
for ( var k=0, ken=classNames.length ; k<ken ; k++ ) {
|
23532 |
+
var className = $.trim( classNames[k] );
|
23533 |
+
|
23534 |
+
if ( className === 'all' ) {
|
23535 |
+
// Include in all
|
23536 |
+
hasClass = true;
|
23537 |
+
col.includeIn = $.map( breakpoints, function (a) {
|
23538 |
+
return a.name;
|
23539 |
+
} );
|
23540 |
+
return;
|
23541 |
+
}
|
23542 |
+
else if ( className === 'none' || col.never ) {
|
23543 |
+
// Include in none (default) and no auto
|
23544 |
+
hasClass = true;
|
23545 |
+
return;
|
23546 |
+
}
|
23547 |
+
else if ( className === 'control' ) {
|
23548 |
+
// Special column that is only visible, when one of the other
|
23549 |
+
// columns is hidden. This is used for the details control
|
23550 |
+
hasClass = true;
|
23551 |
+
col.control = true;
|
23552 |
+
return;
|
23553 |
+
}
|
23554 |
+
|
23555 |
+
$.each( breakpoints, function ( j, breakpoint ) {
|
23556 |
+
// Does this column have a class that matches this breakpoint?
|
23557 |
+
var brokenPoint = breakpoint.name.split('-');
|
23558 |
+
var re = new RegExp( '(min\\-|max\\-|not\\-)?('+brokenPoint[0]+')(\\-[_a-zA-Z0-9])?' );
|
23559 |
+
var match = className.match( re );
|
23560 |
+
|
23561 |
+
if ( match ) {
|
23562 |
+
hasClass = true;
|
23563 |
+
|
23564 |
+
if ( match[2] === brokenPoint[0] && match[3] === '-'+brokenPoint[1] ) {
|
23565 |
+
// Class name matches breakpoint name fully
|
23566 |
+
column( i, breakpoint.name, match[1], match[2]+match[3] );
|
23567 |
+
}
|
23568 |
+
else if ( match[2] === brokenPoint[0] && ! match[3] ) {
|
23569 |
+
// Class name matched primary breakpoint name with no qualifier
|
23570 |
+
column( i, breakpoint.name, match[1], match[2] );
|
23571 |
+
}
|
23572 |
+
}
|
23573 |
+
} );
|
23574 |
+
}
|
23575 |
+
|
23576 |
+
// If there was no control class, then automatic sizing is used
|
23577 |
+
if ( ! hasClass ) {
|
23578 |
+
col.auto = true;
|
23579 |
+
}
|
23580 |
+
} );
|
23581 |
+
|
23582 |
+
this.s.columns = columns;
|
23583 |
+
},
|
23584 |
+
|
23585 |
+
|
23586 |
+
/**
|
23587 |
+
* Show the details for the child row
|
23588 |
+
*
|
23589 |
+
* @param {DataTables.Api} row API instance for the row
|
23590 |
+
* @param {boolean} update Update flag
|
23591 |
+
* @private
|
23592 |
+
*/
|
23593 |
+
_detailsDisplay: function ( row, update )
|
23594 |
+
{
|
23595 |
+
var that = this;
|
23596 |
+
var dt = this.s.dt;
|
23597 |
+
var details = this.c.details;
|
23598 |
+
|
23599 |
+
if ( details && details.type !== false ) {
|
23600 |
+
var res = details.display( row, update, function () {
|
23601 |
+
return details.renderer(
|
23602 |
+
dt, row[0], that._detailsObj(row[0])
|
23603 |
+
);
|
23604 |
+
} );
|
23605 |
+
|
23606 |
+
if ( res === true || res === false ) {
|
23607 |
+
$(dt.table().node()).triggerHandler( 'responsive-display.dt', [dt, row, res, update] );
|
23608 |
+
}
|
23609 |
+
}
|
23610 |
+
},
|
23611 |
+
|
23612 |
+
|
23613 |
+
/**
|
23614 |
+
* Initialisation for the details handler
|
23615 |
+
*
|
23616 |
+
* @private
|
23617 |
+
*/
|
23618 |
+
_detailsInit: function ()
|
23619 |
+
{
|
23620 |
+
var that = this;
|
23621 |
+
var dt = this.s.dt;
|
23622 |
+
var details = this.c.details;
|
23623 |
+
|
23624 |
+
// The inline type always uses the first child as the target
|
23625 |
+
if ( details.type === 'inline' ) {
|
23626 |
+
details.target = 'td:first-child, th:first-child';
|
23627 |
+
}
|
23628 |
+
|
23629 |
+
// Keyboard accessibility
|
23630 |
+
dt.on( 'draw.dtr', function () {
|
23631 |
+
that._tabIndexes();
|
23632 |
+
} );
|
23633 |
+
that._tabIndexes(); // Initial draw has already happened
|
23634 |
+
|
23635 |
+
$( dt.table().body() ).on( 'keyup.dtr', 'td, th', function (e) {
|
23636 |
+
if ( e.keyCode === 13 && $(this).data('dtr-keyboard') ) {
|
23637 |
+
$(this).click();
|
23638 |
+
}
|
23639 |
+
} );
|
23640 |
+
|
23641 |
+
// type.target can be a string jQuery selector or a column index
|
23642 |
+
var target = details.target;
|
23643 |
+
var selector = typeof target === 'string' ? target : 'td, th';
|
23644 |
+
|
23645 |
+
// Click handler to show / hide the details rows when they are available
|
23646 |
+
$( dt.table().body() )
|
23647 |
+
.on( 'click.dtr mousedown.dtr mouseup.dtr', selector, function (e) {
|
23648 |
+
// If the table is not collapsed (i.e. there is no hidden columns)
|
23649 |
+
// then take no action
|
23650 |
+
if ( ! $(dt.table().node()).hasClass('collapsed' ) ) {
|
23651 |
+
return;
|
23652 |
+
}
|
23653 |
+
|
23654 |
+
// Check that the row is actually a DataTable's controlled node
|
23655 |
+
if ( $.inArray( $(this).closest('tr').get(0), dt.rows().nodes().toArray() ) === -1 ) {
|
23656 |
+
return;
|
23657 |
+
}
|
23658 |
+
|
23659 |
+
// For column index, we determine if we should act or not in the
|
23660 |
+
// handler - otherwise it is already okay
|
23661 |
+
if ( typeof target === 'number' ) {
|
23662 |
+
var targetIdx = target < 0 ?
|
23663 |
+
dt.columns().eq(0).length + target :
|
23664 |
+
target;
|
23665 |
+
|
23666 |
+
if ( dt.cell( this ).index().column !== targetIdx ) {
|
23667 |
+
return;
|
23668 |
+
}
|
23669 |
+
}
|
23670 |
+
|
23671 |
+
// $().closest() includes itself in its check
|
23672 |
+
var row = dt.row( $(this).closest('tr') );
|
23673 |
+
|
23674 |
+
// Check event type to do an action
|
23675 |
+
if ( e.type === 'click' ) {
|
23676 |
+
// The renderer is given as a function so the caller can execute it
|
23677 |
+
// only when they need (i.e. if hiding there is no point is running
|
23678 |
+
// the renderer)
|
23679 |
+
that._detailsDisplay( row, false );
|
23680 |
+
}
|
23681 |
+
else if ( e.type === 'mousedown' ) {
|
23682 |
+
// For mouse users, prevent the focus ring from showing
|
23683 |
+
$(this).css('outline', 'none');
|
23684 |
+
}
|
23685 |
+
else if ( e.type === 'mouseup' ) {
|
23686 |
+
// And then re-allow at the end of the click
|
23687 |
+
$(this).blur().css('outline', '');
|
23688 |
+
}
|
23689 |
+
} );
|
23690 |
+
},
|
23691 |
+
|
23692 |
+
|
23693 |
+
/**
|
23694 |
+
* Get the details to pass to a renderer for a row
|
23695 |
+
* @param {int} rowIdx Row index
|
23696 |
+
* @private
|
23697 |
+
*/
|
23698 |
+
_detailsObj: function ( rowIdx )
|
23699 |
+
{
|
23700 |
+
var that = this;
|
23701 |
+
var dt = this.s.dt;
|
23702 |
+
|
23703 |
+
return $.map( this.s.columns, function( col, i ) {
|
23704 |
+
// Never and control columns should not be passed to the renderer
|
23705 |
+
if ( col.never || col.control ) {
|
23706 |
+
return;
|
23707 |
+
}
|
23708 |
+
|
23709 |
+
return {
|
23710 |
+
title: dt.settings()[0].aoColumns[ i ].sTitle,
|
23711 |
+
data: dt.cell( rowIdx, i ).render( that.c.orthogonal ),
|
23712 |
+
hidden: dt.column( i ).visible() && !that.s.current[ i ],
|
23713 |
+
columnIndex: i,
|
23714 |
+
rowIndex: rowIdx
|
23715 |
+
};
|
23716 |
+
} );
|
23717 |
+
},
|
23718 |
+
|
23719 |
+
|
23720 |
+
/**
|
23721 |
+
* Find a breakpoint object from a name
|
23722 |
+
*
|
23723 |
+
* @param {string} name Breakpoint name to find
|
23724 |
+
* @return {object} Breakpoint description object
|
23725 |
+
* @private
|
23726 |
+
*/
|
23727 |
+
_find: function ( name )
|
23728 |
+
{
|
23729 |
+
var breakpoints = this.c.breakpoints;
|
23730 |
+
|
23731 |
+
for ( var i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
23732 |
+
if ( breakpoints[i].name === name ) {
|
23733 |
+
return breakpoints[i];
|
23734 |
+
}
|
23735 |
+
}
|
23736 |
+
},
|
23737 |
+
|
23738 |
+
|
23739 |
+
/**
|
23740 |
+
* Re-create the contents of the child rows as the display has changed in
|
23741 |
+
* some way.
|
23742 |
+
*
|
23743 |
+
* @private
|
23744 |
+
*/
|
23745 |
+
_redrawChildren: function ()
|
23746 |
+
{
|
23747 |
+
var that = this;
|
23748 |
+
var dt = this.s.dt;
|
23749 |
+
|
23750 |
+
dt.rows( {page: 'current'} ).iterator( 'row', function ( settings, idx ) {
|
23751 |
+
var row = dt.row( idx );
|
23752 |
+
|
23753 |
+
that._detailsDisplay( dt.row( idx ), true );
|
23754 |
+
} );
|
23755 |
+
},
|
23756 |
+
|
23757 |
+
|
23758 |
+
/**
|
23759 |
+
* Alter the table display for a resized viewport. This involves first
|
23760 |
+
* determining what breakpoint the window currently is in, getting the
|
23761 |
+
* column visibilities to apply and then setting them.
|
23762 |
+
*
|
23763 |
+
* @private
|
23764 |
+
*/
|
23765 |
+
_resize: function ()
|
23766 |
+
{
|
23767 |
+
var that = this;
|
23768 |
+
var dt = this.s.dt;
|
23769 |
+
var width = $(window).width();
|
23770 |
+
var breakpoints = this.c.breakpoints;
|
23771 |
+
var breakpoint = breakpoints[0].name;
|
23772 |
+
var columns = this.s.columns;
|
23773 |
+
var i, ien;
|
23774 |
+
var oldVis = this.s.current.slice();
|
23775 |
+
|
23776 |
+
// Determine what breakpoint we are currently at
|
23777 |
+
for ( i=breakpoints.length-1 ; i>=0 ; i-- ) {
|
23778 |
+
if ( width <= breakpoints[i].width ) {
|
23779 |
+
breakpoint = breakpoints[i].name;
|
23780 |
+
break;
|
23781 |
+
}
|
23782 |
+
}
|
23783 |
+
|
23784 |
+
// Show the columns for that break point
|
23785 |
+
var columnsVis = this._columnsVisiblity( breakpoint );
|
23786 |
+
this.s.current = columnsVis;
|
23787 |
+
|
23788 |
+
// Set the class before the column visibility is changed so event
|
23789 |
+
// listeners know what the state is. Need to determine if there are
|
23790 |
+
// any columns that are not visible but can be shown
|
23791 |
+
var collapsedClass = false;
|
23792 |
+
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
23793 |
+
if ( columnsVis[i] === false && ! columns[i].never && ! columns[i].control ) {
|
23794 |
+
collapsedClass = true;
|
23795 |
+
break;
|
23796 |
+
}
|
23797 |
+
}
|
23798 |
+
|
23799 |
+
$( dt.table().node() ).toggleClass( 'collapsed', collapsedClass );
|
23800 |
+
|
23801 |
+
var changed = false;
|
23802 |
+
var visible = 0;
|
23803 |
+
|
23804 |
+
dt.columns().eq(0).each( function ( colIdx, i ) {
|
23805 |
+
if ( columnsVis[i] === true ) {
|
23806 |
+
visible++;
|
23807 |
+
}
|
23808 |
+
|
23809 |
+
if ( columnsVis[i] !== oldVis[i] ) {
|
23810 |
+
changed = true;
|
23811 |
+
that._setColumnVis( colIdx, columnsVis[i] );
|
23812 |
+
}
|
23813 |
+
} );
|
23814 |
+
|
23815 |
+
if ( changed ) {
|
23816 |
+
this._redrawChildren();
|
23817 |
+
|
23818 |
+
// Inform listeners of the change
|
23819 |
+
$(dt.table().node()).trigger( 'responsive-resize.dt', [dt, this.s.current] );
|
23820 |
+
|
23821 |
+
// If no records, update the "No records" display element
|
23822 |
+
if ( dt.page.info().recordsDisplay === 0 ) {
|
23823 |
+
$('td', dt.table().body()).eq(0).attr('colspan', visible);
|
23824 |
+
}
|
23825 |
+
}
|
23826 |
+
},
|
23827 |
+
|
23828 |
+
|
23829 |
+
/**
|
23830 |
+
* Determine the width of each column in the table so the auto column hiding
|
23831 |
+
* has that information to work with. This method is never going to be 100%
|
23832 |
+
* perfect since column widths can change slightly per page, but without
|
23833 |
+
* seriously compromising performance this is quite effective.
|
23834 |
+
*
|
23835 |
+
* @private
|
23836 |
+
*/
|
23837 |
+
_resizeAuto: function ()
|
23838 |
+
{
|
23839 |
+
var dt = this.s.dt;
|
23840 |
+
var columns = this.s.columns;
|
23841 |
+
|
23842 |
+
// Are we allowed to do auto sizing?
|
23843 |
+
if ( ! this.c.auto ) {
|
23844 |
+
return;
|
23845 |
+
}
|
23846 |
+
|
23847 |
+
// Are there any columns that actually need auto-sizing, or do they all
|
23848 |
+
// have classes defined
|
23849 |
+
if ( $.inArray( true, $.map( columns, function (c) { return c.auto; } ) ) === -1 ) {
|
23850 |
+
return;
|
23851 |
+
}
|
23852 |
+
|
23853 |
+
// Need to restore all children. They will be reinstated by a re-render
|
23854 |
+
if ( ! $.isEmptyObject( _childNodeStore ) ) {
|
23855 |
+
$.each( _childNodeStore, function ( key ) {
|
23856 |
+
var idx = key.split('-');
|
23857 |
+
|
23858 |
+
_childNodesRestore( dt, idx[0]*1, idx[1]*1 );
|
23859 |
+
} );
|
23860 |
+
}
|
23861 |
+
|
23862 |
+
// Clone the table with the current data in it
|
23863 |
+
var tableWidth = dt.table().node().offsetWidth;
|
23864 |
+
var columnWidths = dt.columns;
|
23865 |
+
var clonedTable = dt.table().node().cloneNode( false );
|
23866 |
+
var clonedHeader = $( dt.table().header().cloneNode( false ) ).appendTo( clonedTable );
|
23867 |
+
var clonedBody = $( dt.table().body() ).clone( false, false ).empty().appendTo( clonedTable ); // use jQuery because of IE8
|
23868 |
+
|
23869 |
+
// Header
|
23870 |
+
var headerCells = dt.columns()
|
23871 |
+
.header()
|
23872 |
+
.filter( function (idx) {
|
23873 |
+
return dt.column(idx).visible();
|
23874 |
+
} )
|
23875 |
+
.to$()
|
23876 |
+
.clone( false )
|
23877 |
+
.css( 'display', 'table-cell' )
|
23878 |
+
.css( 'min-width', 0 );
|
23879 |
+
|
23880 |
+
// Body rows - we don't need to take account of DataTables' column
|
23881 |
+
// visibility since we implement our own here (hence the `display` set)
|
23882 |
+
$(clonedBody)
|
23883 |
+
.append( $(dt.rows( { page: 'current' } ).nodes()).clone( false ) )
|
23884 |
+
.find( 'th, td' ).css( 'display', '' );
|
23885 |
+
|
23886 |
+
// Footer
|
23887 |
+
var footer = dt.table().footer();
|
23888 |
+
if ( footer ) {
|
23889 |
+
var clonedFooter = $( footer.cloneNode( false ) ).appendTo( clonedTable );
|
23890 |
+
var footerCells = dt.columns()
|
23891 |
+
.footer()
|
23892 |
+
.filter( function (idx) {
|
23893 |
+
return dt.column(idx).visible();
|
23894 |
+
} )
|
23895 |
+
.to$()
|
23896 |
+
.clone( false )
|
23897 |
+
.css( 'display', 'table-cell' );
|
23898 |
+
|
23899 |
+
$('<tr/>')
|
23900 |
+
.append( footerCells )
|
23901 |
+
.appendTo( clonedFooter );
|
23902 |
+
}
|
23903 |
+
|
23904 |
+
$('<tr/>')
|
23905 |
+
.append( headerCells )
|
23906 |
+
.appendTo( clonedHeader );
|
23907 |
+
|
23908 |
+
// In the inline case extra padding is applied to the first column to
|
23909 |
+
// give space for the show / hide icon. We need to use this in the
|
23910 |
+
// calculation
|
23911 |
+
if ( this.c.details.type === 'inline' ) {
|
23912 |
+
$(clonedTable).addClass( 'dtr-inline collapsed' );
|
23913 |
+
}
|
23914 |
+
|
23915 |
+
// It is unsafe to insert elements with the same name into the DOM
|
23916 |
+
// multiple times. For example, cloning and inserting a checked radio
|
23917 |
+
// clears the chcecked state of the original radio.
|
23918 |
+
$( clonedTable ).find( '[name]' ).removeAttr( 'name' );
|
23919 |
+
|
23920 |
+
var inserted = $('<div/>')
|
23921 |
+
.css( {
|
23922 |
+
width: 1,
|
23923 |
+
height: 1,
|
23924 |
+
overflow: 'hidden',
|
23925 |
+
clear: 'both'
|
23926 |
+
} )
|
23927 |
+
.append( clonedTable );
|
23928 |
+
|
23929 |
+
inserted.insertBefore( dt.table().node() );
|
23930 |
+
|
23931 |
+
// The cloned header now contains the smallest that each column can be
|
23932 |
+
headerCells.each( function (i) {
|
23933 |
+
var idx = dt.column.index( 'fromVisible', i );
|
23934 |
+
columns[ idx ].minWidth = this.offsetWidth || 0;
|
23935 |
+
} );
|
23936 |
+
|
23937 |
+
inserted.remove();
|
23938 |
+
},
|
23939 |
+
|
23940 |
+
/**
|
23941 |
+
* Set a column's visibility.
|
23942 |
+
*
|
23943 |
+
* We don't use DataTables' column visibility controls in order to ensure
|
23944 |
+
* that column visibility can Responsive can no-exist. Since only IE8+ is
|
23945 |
+
* supported (and all evergreen browsers of course) the control of the
|
23946 |
+
* display attribute works well.
|
23947 |
+
*
|
23948 |
+
* @param {integer} col Column index
|
23949 |
+
* @param {boolean} showHide Show or hide (true or false)
|
23950 |
+
* @private
|
23951 |
+
*/
|
23952 |
+
_setColumnVis: function ( col, showHide )
|
23953 |
+
{
|
23954 |
+
var dt = this.s.dt;
|
23955 |
+
var display = showHide ? '' : 'none'; // empty string will remove the attr
|
23956 |
+
|
23957 |
+
$( dt.column( col ).header() ).css( 'display', display );
|
23958 |
+
$( dt.column( col ).footer() ).css( 'display', display );
|
23959 |
+
dt.column( col ).nodes().to$().css( 'display', display );
|
23960 |
+
|
23961 |
+
// If the are child nodes stored, we might need to reinsert them
|
23962 |
+
if ( ! $.isEmptyObject( _childNodeStore ) ) {
|
23963 |
+
dt.cells( null, col ).indexes().each( function (idx) {
|
23964 |
+
_childNodesRestore( dt, idx.row, idx.column );
|
23965 |
+
} );
|
23966 |
+
}
|
23967 |
+
},
|
23968 |
+
|
23969 |
+
|
23970 |
+
/**
|
23971 |
+
* Update the cell tab indexes for keyboard accessibility. This is called on
|
23972 |
+
* every table draw - that is potentially inefficient, but also the least
|
23973 |
+
* complex option given that column visibility can change on the fly. Its a
|
23974 |
+
* shame user-focus was removed from CSS 3 UI, as it would have solved this
|
23975 |
+
* issue with a single CSS statement.
|
23976 |
+
*
|
23977 |
+
* @private
|
23978 |
+
*/
|
23979 |
+
_tabIndexes: function ()
|
23980 |
+
{
|
23981 |
+
var dt = this.s.dt;
|
23982 |
+
var cells = dt.cells( { page: 'current' } ).nodes().to$();
|
23983 |
+
var ctx = dt.settings()[0];
|
23984 |
+
var target = this.c.details.target;
|
23985 |
+
|
23986 |
+
cells.filter( '[data-dtr-keyboard]' ).removeData( '[data-dtr-keyboard]' );
|
23987 |
+
|
23988 |
+
var selector = typeof target === 'number' ?
|
23989 |
+
':eq('+target+')' :
|
23990 |
+
target;
|
23991 |
+
|
23992 |
+
// This is a bit of a hack - we need to limit the selected nodes to just
|
23993 |
+
// those of this table
|
23994 |
+
if ( selector === 'td:first-child, th:first-child' ) {
|
23995 |
+
selector = '>td:first-child, >th:first-child';
|
23996 |
+
}
|
23997 |
+
|
23998 |
+
$( selector, dt.rows( { page: 'current' } ).nodes() )
|
23999 |
+
.attr( 'tabIndex', ctx.iTabIndex )
|
24000 |
+
.data( 'dtr-keyboard', 1 );
|
24001 |
+
}
|
24002 |
+
} );
|
24003 |
+
|
24004 |
+
|
24005 |
+
/**
|
24006 |
+
* List of default breakpoints. Each item in the array is an object with two
|
24007 |
+
* properties:
|
24008 |
+
*
|
24009 |
+
* * `name` - the breakpoint name.
|
24010 |
+
* * `width` - the breakpoint width
|
24011 |
+
*
|
24012 |
+
* @name Responsive.breakpoints
|
24013 |
+
* @static
|
24014 |
+
*/
|
24015 |
+
Responsive.breakpoints = [
|
24016 |
+
{ name: 'desktop', width: Infinity },
|
24017 |
+
{ name: 'tablet-l', width: 1024 },
|
24018 |
+
{ name: 'tablet-p', width: 768 },
|
24019 |
+
{ name: 'mobile-l', width: 480 },
|
24020 |
+
{ name: 'mobile-p', width: 320 }
|
24021 |
+
];
|
24022 |
+
|
24023 |
+
|
24024 |
+
/**
|
24025 |
+
* Display methods - functions which define how the hidden data should be shown
|
24026 |
+
* in the table.
|
24027 |
+
*
|
24028 |
+
* @namespace
|
24029 |
+
* @name Responsive.defaults
|
24030 |
+
* @static
|
24031 |
+
*/
|
24032 |
+
Responsive.display = {
|
24033 |
+
childRow: function ( row, update, render ) {
|
24034 |
+
if ( update ) {
|
24035 |
+
if ( $(row.node()).hasClass('parent') ) {
|
24036 |
+
row.child( render(), 'child' ).show();
|
24037 |
+
|
24038 |
+
return true;
|
24039 |
+
}
|
24040 |
+
}
|
24041 |
+
else {
|
24042 |
+
if ( ! row.child.isShown() ) {
|
24043 |
+
row.child( render(), 'child' ).show();
|
24044 |
+
$( row.node() ).addClass( 'parent' );
|
24045 |
+
|
24046 |
+
return true;
|
24047 |
+
}
|
24048 |
+
else {
|
24049 |
+
row.child( false );
|
24050 |
+
$( row.node() ).removeClass( 'parent' );
|
24051 |
+
|
24052 |
+
return false;
|
24053 |
+
}
|
24054 |
+
}
|
24055 |
+
},
|
24056 |
+
|
24057 |
+
childRowImmediate: function ( row, update, render ) {
|
24058 |
+
if ( (! update && row.child.isShown()) || ! row.responsive.hasHidden() ) {
|
24059 |
+
// User interaction and the row is show, or nothing to show
|
24060 |
+
row.child( false );
|
24061 |
+
$( row.node() ).removeClass( 'parent' );
|
24062 |
+
|
24063 |
+
return false;
|
24064 |
+
}
|
24065 |
+
else {
|
24066 |
+
// Display
|
24067 |
+
row.child( render(), 'child' ).show();
|
24068 |
+
$( row.node() ).addClass( 'parent' );
|
24069 |
+
|
24070 |
+
return true;
|
24071 |
+
}
|
24072 |
+
},
|
24073 |
+
|
24074 |
+
// This is a wrapper so the modal options for Bootstrap and jQuery UI can
|
24075 |
+
// have options passed into them. This specific one doesn't need to be a
|
24076 |
+
// function but it is for consistency in the `modal` name
|
24077 |
+
modal: function ( options ) {
|
24078 |
+
return function ( row, update, render ) {
|
24079 |
+
if ( ! update ) {
|
24080 |
+
// Show a modal
|
24081 |
+
var close = function () {
|
24082 |
+
modal.remove(); // will tidy events for us
|
24083 |
+
$(document).off( 'keypress.dtr' );
|
24084 |
+
};
|
24085 |
+
|
24086 |
+
var modal = $('<div class="dtr-modal"/>')
|
24087 |
+
.append( $('<div class="dtr-modal-display"/>')
|
24088 |
+
.append( $('<div class="dtr-modal-content"/>')
|
24089 |
+
.append( render() )
|
24090 |
+
)
|
24091 |
+
.append( $('<div class="dtr-modal-close">×</div>' )
|
24092 |
+
.click( function () {
|
24093 |
+
close();
|
24094 |
+
} )
|
24095 |
+
)
|
24096 |
+
)
|
24097 |
+
.append( $('<div class="dtr-modal-background"/>')
|
24098 |
+
.click( function () {
|
24099 |
+
close();
|
24100 |
+
} )
|
24101 |
+
)
|
24102 |
+
.appendTo( 'body' );
|
24103 |
+
|
24104 |
+
$(document).on( 'keyup.dtr', function (e) {
|
24105 |
+
if ( e.keyCode === 27 ) {
|
24106 |
+
e.stopPropagation();
|
24107 |
+
|
24108 |
+
close();
|
24109 |
+
}
|
24110 |
+
} );
|
24111 |
+
}
|
24112 |
+
else {
|
24113 |
+
$('div.dtr-modal-content')
|
24114 |
+
.empty()
|
24115 |
+
.append( render() );
|
24116 |
+
}
|
24117 |
+
|
24118 |
+
if ( options && options.header ) {
|
24119 |
+
$('div.dtr-modal-content').prepend(
|
24120 |
+
'<h2>'+options.header( row )+'</h2>'
|
24121 |
+
);
|
24122 |
+
}
|
24123 |
+
};
|
24124 |
+
}
|
24125 |
+
};
|
24126 |
+
|
24127 |
+
|
24128 |
+
var _childNodeStore = {};
|
24129 |
+
|
24130 |
+
function _childNodes( dt, row, col ) {
|
24131 |
+
var name = row+'-'+col;
|
24132 |
+
|
24133 |
+
if ( _childNodeStore[ name ] ) {
|
24134 |
+
return _childNodeStore[ name ];
|
24135 |
+
}
|
24136 |
+
|
24137 |
+
// https://jsperf.com/childnodes-array-slice-vs-loop
|
24138 |
+
var nodes = [];
|
24139 |
+
var children = dt.cell( row, col ).node().childNodes;
|
24140 |
+
for ( var i=0, ien=children.length ; i<ien ; i++ ) {
|
24141 |
+
nodes.push( children[i] );
|
24142 |
+
}
|
24143 |
+
|
24144 |
+
_childNodeStore[ name ] = nodes;
|
24145 |
+
|
24146 |
+
return nodes;
|
24147 |
+
}
|
24148 |
+
|
24149 |
+
function _childNodesRestore( dt, row, col ) {
|
24150 |
+
var name = row+'-'+col;
|
24151 |
+
|
24152 |
+
if ( ! _childNodeStore[ name ] ) {
|
24153 |
+
return;
|
24154 |
+
}
|
24155 |
+
|
24156 |
+
var node = dt.cell( row, col ).node();
|
24157 |
+
var store = _childNodeStore[ name ];
|
24158 |
+
var parent = store[0].parentNode;
|
24159 |
+
var parentChildren = parent.childNodes;
|
24160 |
+
var a = [];
|
24161 |
+
|
24162 |
+
for ( var i=0, ien=parentChildren.length ; i<ien ; i++ ) {
|
24163 |
+
a.push( parentChildren[i] );
|
24164 |
+
}
|
24165 |
+
|
24166 |
+
for ( var j=0, jen=a.length ; j<jen ; j++ ) {
|
24167 |
+
node.appendChild( a[j] );
|
24168 |
+
}
|
24169 |
+
|
24170 |
+
_childNodeStore[ name ] = undefined;
|
24171 |
+
}
|
24172 |
+
|
24173 |
+
|
24174 |
+
/**
|
24175 |
+
* Display methods - functions which define how the hidden data should be shown
|
24176 |
+
* in the table.
|
24177 |
+
*
|
24178 |
+
* @namespace
|
24179 |
+
* @name Responsive.defaults
|
24180 |
+
* @static
|
24181 |
+
*/
|
24182 |
+
Responsive.renderer = {
|
24183 |
+
listHiddenNodes: function () {
|
24184 |
+
return function ( api, rowIdx, columns ) {
|
24185 |
+
var ul = $('<ul data-dtr-index="'+rowIdx+'" class="dtr-details"/>');
|
24186 |
+
var found = false;
|
24187 |
+
|
24188 |
+
var data = $.each( columns, function ( i, col ) {
|
24189 |
+
if ( col.hidden ) {
|
24190 |
+
$(
|
24191 |
+
'<li data-dtr-index="'+col.columnIndex+'" data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">'+
|
24192 |
+
'<span class="dtr-title">'+
|
24193 |
+
col.title+
|
24194 |
+
'</span> '+
|
24195 |
+
'</li>'
|
24196 |
+
)
|
24197 |
+
.append( $('<span class="dtr-data"/>').append( _childNodes( api, col.rowIndex, col.columnIndex ) ) )// api.cell( col.rowIndex, col.columnIndex ).node().childNodes ) )
|
24198 |
+
.appendTo( ul );
|
24199 |
+
|
24200 |
+
found = true;
|
24201 |
+
}
|
24202 |
+
} );
|
24203 |
+
|
24204 |
+
return found ?
|
24205 |
+
ul :
|
24206 |
+
false;
|
24207 |
+
};
|
24208 |
+
},
|
24209 |
+
|
24210 |
+
listHidden: function () {
|
24211 |
+
return function ( api, rowIdx, columns ) {
|
24212 |
+
var data = $.map( columns, function ( col ) {
|
24213 |
+
return col.hidden ?
|
24214 |
+
'<li data-dtr-index="'+col.columnIndex+'" data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">'+
|
24215 |
+
'<span class="dtr-title">'+
|
24216 |
+
col.title+
|
24217 |
+
'</span> '+
|
24218 |
+
'<span class="dtr-data">'+
|
24219 |
+
col.data+
|
24220 |
+
'</span>'+
|
24221 |
+
'</li>' :
|
24222 |
+
'';
|
24223 |
+
} ).join('');
|
24224 |
+
|
24225 |
+
return data ?
|
24226 |
+
$('<ul data-dtr-index="'+rowIdx+'" class="dtr-details"/>').append( data ) :
|
24227 |
+
false;
|
24228 |
+
}
|
24229 |
+
},
|
24230 |
+
|
24231 |
+
tableAll: function ( options ) {
|
24232 |
+
options = $.extend( {
|
24233 |
+
tableClass: ''
|
24234 |
+
}, options );
|
24235 |
+
|
24236 |
+
return function ( api, rowIdx, columns ) {
|
24237 |
+
var data = $.map( columns, function ( col ) {
|
24238 |
+
return '<tr data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">'+
|
24239 |
+
'<td>'+col.title+':'+'</td> '+
|
24240 |
+
'<td>'+col.data+'</td>'+
|
24241 |
+
'</tr>';
|
24242 |
+
} ).join('');
|
24243 |
+
|
24244 |
+
return $('<table class="'+options.tableClass+' dtr-details" width="100%"/>').append( data );
|
24245 |
+
}
|
24246 |
+
}
|
24247 |
+
};
|
24248 |
+
|
24249 |
+
/**
|
24250 |
+
* Responsive default settings for initialisation
|
24251 |
+
*
|
24252 |
+
* @namespace
|
24253 |
+
* @name Responsive.defaults
|
24254 |
+
* @static
|
24255 |
+
*/
|
24256 |
+
Responsive.defaults = {
|
24257 |
+
/**
|
24258 |
+
* List of breakpoints for the instance. Note that this means that each
|
24259 |
+
* instance can have its own breakpoints. Additionally, the breakpoints
|
24260 |
+
* cannot be changed once an instance has been creased.
|
24261 |
+
*
|
24262 |
+
* @type {Array}
|
24263 |
+
* @default Takes the value of `Responsive.breakpoints`
|
24264 |
+
*/
|
24265 |
+
breakpoints: Responsive.breakpoints,
|
24266 |
+
|
24267 |
+
/**
|
24268 |
+
* Enable / disable auto hiding calculations. It can help to increase
|
24269 |
+
* performance slightly if you disable this option, but all columns would
|
24270 |
+
* need to have breakpoint classes assigned to them
|
24271 |
+
*
|
24272 |
+
* @type {Boolean}
|
24273 |
+
* @default `true`
|
24274 |
+
*/
|
24275 |
+
auto: true,
|
24276 |
+
|
24277 |
+
/**
|
24278 |
+
* Details control. If given as a string value, the `type` property of the
|
24279 |
+
* default object is set to that value, and the defaults used for the rest
|
24280 |
+
* of the object - this is for ease of implementation.
|
24281 |
+
*
|
24282 |
+
* The object consists of the following properties:
|
24283 |
+
*
|
24284 |
+
* * `display` - A function that is used to show and hide the hidden details
|
24285 |
+
* * `renderer` - function that is called for display of the child row data.
|
24286 |
+
* The default function will show the data from the hidden columns
|
24287 |
+
* * `target` - Used as the selector for what objects to attach the child
|
24288 |
+
* open / close to
|
24289 |
+
* * `type` - `false` to disable the details display, `inline` or `column`
|
24290 |
+
* for the two control types
|
24291 |
+
*
|
24292 |
+
* @type {Object|string}
|
24293 |
+
*/
|
24294 |
+
details: {
|
24295 |
+
display: Responsive.display.childRow,
|
24296 |
+
|
24297 |
+
renderer: Responsive.renderer.listHidden(),
|
24298 |
+
|
24299 |
+
target: 0,
|
24300 |
+
|
24301 |
+
type: 'inline'
|
24302 |
+
},
|
24303 |
+
|
24304 |
+
/**
|
24305 |
+
* Orthogonal data request option. This is used to define the data type
|
24306 |
+
* requested when Responsive gets the data to show in the child row.
|
24307 |
+
*
|
24308 |
+
* @type {String}
|
24309 |
+
*/
|
24310 |
+
orthogonal: 'display'
|
24311 |
+
};
|
24312 |
+
|
24313 |
+
|
24314 |
+
/*
|
24315 |
+
* API
|
24316 |
+
*/
|
24317 |
+
var Api = $.fn.dataTable.Api;
|
24318 |
+
|
24319 |
+
// Doesn't do anything - work around for a bug in DT... Not documented
|
24320 |
+
Api.register( 'responsive()', function () {
|
24321 |
+
return this;
|
24322 |
+
} );
|
24323 |
+
|
24324 |
+
Api.register( 'responsive.index()', function ( li ) {
|
24325 |
+
li = $(li);
|
24326 |
+
|
24327 |
+
return {
|
24328 |
+
column: li.data('dtr-index'),
|
24329 |
+
row: li.parent().data('dtr-index')
|
24330 |
+
};
|
24331 |
+
} );
|
24332 |
+
|
24333 |
+
Api.register( 'responsive.rebuild()', function () {
|
24334 |
+
return this.iterator( 'table', function ( ctx ) {
|
24335 |
+
if ( ctx._responsive ) {
|
24336 |
+
ctx._responsive._classLogic();
|
24337 |
+
}
|
24338 |
+
} );
|
24339 |
+
} );
|
24340 |
+
|
24341 |
+
Api.register( 'responsive.recalc()', function () {
|
24342 |
+
return this.iterator( 'table', function ( ctx ) {
|
24343 |
+
if ( ctx._responsive ) {
|
24344 |
+
ctx._responsive._resizeAuto();
|
24345 |
+
ctx._responsive._resize();
|
24346 |
+
}
|
24347 |
+
} );
|
24348 |
+
} );
|
24349 |
+
|
24350 |
+
Api.register( 'responsive.hasHidden()', function () {
|
24351 |
+
var ctx = this.context[0];
|
24352 |
+
|
24353 |
+
return ctx._responsive ?
|
24354 |
+
$.inArray( false, ctx._responsive.s.current ) !== -1 :
|
24355 |
+
false;
|
24356 |
+
} );
|
24357 |
+
|
24358 |
+
Api.registerPlural( 'columns().responsiveHidden()', 'column().responsiveHidden()', function () {
|
24359 |
+
return this.iterator( 'column', function ( settings, column ) {
|
24360 |
+
return settings._responsive ?
|
24361 |
+
settings._responsive.s.current[ column ] :
|
24362 |
+
false;
|
24363 |
+
}, 1 );
|
24364 |
+
} );
|
24365 |
+
|
24366 |
+
|
24367 |
+
/**
|
24368 |
+
* Version information
|
24369 |
+
*
|
24370 |
+
* @name Responsive.version
|
24371 |
+
* @static
|
24372 |
+
*/
|
24373 |
+
Responsive.version = '2.2.1';
|
24374 |
+
|
24375 |
+
|
24376 |
+
$.fn.dataTable.Responsive = Responsive;
|
24377 |
+
$.fn.DataTable.Responsive = Responsive;
|
24378 |
+
|
24379 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
24380 |
+
// events so we can automatically initialise
|
24381 |
+
$(document).on( 'preInit.dt.dtr', function (e, settings, json) {
|
24382 |
+
if ( e.namespace !== 'dt' ) {
|
24383 |
+
return;
|
24384 |
+
}
|
24385 |
+
|
24386 |
+
if ( $(settings.nTable).hasClass( 'responsive' ) ||
|
24387 |
+
$(settings.nTable).hasClass( 'dt-responsive' ) ||
|
24388 |
+
settings.oInit.responsive ||
|
24389 |
+
DataTable.defaults.responsive
|
24390 |
+
) {
|
24391 |
+
var init = settings.oInit.responsive;
|
24392 |
+
|
24393 |
+
if ( init !== false ) {
|
24394 |
+
new Responsive( settings, $.isPlainObject( init ) ? init : {} );
|
24395 |
+
}
|
24396 |
+
}
|
24397 |
+
} );
|
24398 |
+
|
24399 |
+
|
24400 |
+
return Responsive;
|
24401 |
+
}));
|
24402 |
+
|
24403 |
+
|
24404 |
+
/*! RowReorder 1.2.3
|
24405 |
+
* 2015-2017 SpryMedia Ltd - datatables.net/license
|
24406 |
+
*/
|
24407 |
+
|
24408 |
+
/**
|
24409 |
+
* @summary RowReorder
|
24410 |
+
* @description Row reordering extension for DataTables
|
24411 |
+
* @version 1.2.3
|
24412 |
+
* @file dataTables.rowReorder.js
|
24413 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
24414 |
+
* @contact www.sprymedia.co.uk/contact
|
24415 |
+
* @copyright Copyright 2015-2017 SpryMedia Ltd.
|
24416 |
+
*
|
24417 |
+
* This source file is free software, available under the following license:
|
24418 |
+
* MIT license - http://datatables.net/license/mit
|
24419 |
+
*
|
24420 |
+
* This source file is distributed in the hope that it will be useful, but
|
24421 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
24422 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
24423 |
+
*
|
24424 |
+
* For details please refer to: http://www.datatables.net
|
24425 |
+
*/
|
24426 |
+
|
24427 |
+
(function( factory ){
|
24428 |
+
if ( typeof define === 'function' && define.amd ) {
|
24429 |
+
// AMD
|
24430 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
24431 |
+
return factory( $, window, document );
|
24432 |
+
} );
|
24433 |
+
}
|
24434 |
+
else if ( typeof exports === 'object' ) {
|
24435 |
+
// CommonJS
|
24436 |
+
module.exports = function (root, $) {
|
24437 |
+
if ( ! root ) {
|
24438 |
+
root = window;
|
24439 |
+
}
|
24440 |
+
|
24441 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
24442 |
+
$ = require('datatables.net')(root, $).$;
|
24443 |
+
}
|
24444 |
+
|
24445 |
+
return factory( $, root, root.document );
|
24446 |
+
};
|
24447 |
+
}
|
24448 |
+
else {
|
24449 |
+
// Browser
|
24450 |
+
factory( jQuery, window, document );
|
24451 |
+
}
|
24452 |
+
}(function( $, window, document, undefined ) {
|
24453 |
+
'use strict';
|
24454 |
+
var DataTable = $.fn.dataTable;
|
24455 |
+
|
24456 |
+
|
24457 |
+
/**
|
24458 |
+
* RowReorder provides the ability in DataTables to click and drag rows to
|
24459 |
+
* reorder them. When a row is dropped the data for the rows effected will be
|
24460 |
+
* updated to reflect the change. Normally this data point should also be the
|
24461 |
+
* column being sorted upon in the DataTable but this does not need to be the
|
24462 |
+
* case. RowReorder implements a "data swap" method - so the rows being
|
24463 |
+
* reordered take the value of the data point from the row that used to occupy
|
24464 |
+
* the row's new position.
|
24465 |
+
*
|
24466 |
+
* Initialisation is done by either:
|
24467 |
+
*
|
24468 |
+
* * `rowReorder` parameter in the DataTable initialisation object
|
24469 |
+
* * `new $.fn.dataTable.RowReorder( table, opts )` after DataTables
|
24470 |
+
* initialisation.
|
24471 |
+
*
|
24472 |
+
* @class
|
24473 |
+
* @param {object} settings DataTables settings object for the host table
|
24474 |
+
* @param {object} [opts] Configuration options
|
24475 |
+
* @requires jQuery 1.7+
|
24476 |
+
* @requires DataTables 1.10.7+
|
24477 |
+
*/
|
24478 |
+
var RowReorder = function ( dt, opts ) {
|
24479 |
+
// Sanity check that we are using DataTables 1.10 or newer
|
24480 |
+
if ( ! DataTable.versionCheck || ! DataTable.versionCheck( '1.10.8' ) ) {
|
24481 |
+
throw 'DataTables RowReorder requires DataTables 1.10.8 or newer';
|
24482 |
+
}
|
24483 |
+
|
24484 |
+
// User and defaults configuration object
|
24485 |
+
this.c = $.extend( true, {},
|
24486 |
+
DataTable.defaults.rowReorder,
|
24487 |
+
RowReorder.defaults,
|
24488 |
+
opts
|
24489 |
+
);
|
24490 |
+
|
24491 |
+
// Internal settings
|
24492 |
+
this.s = {
|
24493 |
+
/** @type {integer} Scroll body top cache */
|
24494 |
+
bodyTop: null,
|
24495 |
+
|
24496 |
+
/** @type {DataTable.Api} DataTables' API instance */
|
24497 |
+
dt: new DataTable.Api( dt ),
|
24498 |
+
|
24499 |
+
/** @type {function} Data fetch function */
|
24500 |
+
getDataFn: DataTable.ext.oApi._fnGetObjectDataFn( this.c.dataSrc ),
|
24501 |
+
|
24502 |
+
/** @type {array} Pixel positions for row insertion calculation */
|
24503 |
+
middles: null,
|
24504 |
+
|
24505 |
+
/** @type {Object} Cached dimension information for use in the mouse move event handler */
|
24506 |
+
scroll: {},
|
24507 |
+
|
24508 |
+
/** @type {integer} Interval object used for smooth scrolling */
|
24509 |
+
scrollInterval: null,
|
24510 |
+
|
24511 |
+
/** @type {function} Data set function */
|
24512 |
+
setDataFn: DataTable.ext.oApi._fnSetObjectDataFn( this.c.dataSrc ),
|
24513 |
+
|
24514 |
+
/** @type {Object} Mouse down information */
|
24515 |
+
start: {
|
24516 |
+
top: 0,
|
24517 |
+
left: 0,
|
24518 |
+
offsetTop: 0,
|
24519 |
+
offsetLeft: 0,
|
24520 |
+
nodes: []
|
24521 |
+
},
|
24522 |
+
|
24523 |
+
/** @type {integer} Window height cached value */
|
24524 |
+
windowHeight: 0,
|
24525 |
+
|
24526 |
+
/** @type {integer} Document outer height cached value */
|
24527 |
+
documentOuterHeight: 0,
|
24528 |
+
|
24529 |
+
/** @type {integer} DOM clone outer height cached value */
|
24530 |
+
domCloneOuterHeight: 0
|
24531 |
+
};
|
24532 |
+
|
24533 |
+
// DOM items
|
24534 |
+
this.dom = {
|
24535 |
+
/** @type {jQuery} Cloned row being moved around */
|
24536 |
+
clone: null,
|
24537 |
+
|
24538 |
+
/** @type {jQuery} DataTables scrolling container */
|
24539 |
+
dtScroll: $('div.dataTables_scrollBody', this.s.dt.table().container())
|
24540 |
+
};
|
24541 |
+
|
24542 |
+
// Check if row reorder has already been initialised on this table
|
24543 |
+
var settings = this.s.dt.settings()[0];
|
24544 |
+
var exisiting = settings.rowreorder;
|
24545 |
+
if ( exisiting ) {
|
24546 |
+
return exisiting;
|
24547 |
+
}
|
24548 |
+
|
24549 |
+
settings.rowreorder = this;
|
24550 |
+
this._constructor();
|
24551 |
+
};
|
24552 |
+
|
24553 |
+
|
24554 |
+
$.extend( RowReorder.prototype, {
|
24555 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
24556 |
+
* Constructor
|
24557 |
+
*/
|
24558 |
+
|
24559 |
+
/**
|
24560 |
+
* Initialise the RowReorder instance
|
24561 |
+
*
|
24562 |
+
* @private
|
24563 |
+
*/
|
24564 |
+
_constructor: function ()
|
24565 |
+
{
|
24566 |
+
var that = this;
|
24567 |
+
var dt = this.s.dt;
|
24568 |
+
var table = $( dt.table().node() );
|
24569 |
+
|
24570 |
+
// Need to be able to calculate the row positions relative to the table
|
24571 |
+
if ( table.css('position') === 'static' ) {
|
24572 |
+
table.css( 'position', 'relative' );
|
24573 |
+
}
|
24574 |
+
|
24575 |
+
// listen for mouse down on the target column - we have to implement
|
24576 |
+
// this rather than using HTML5 drag and drop as drag and drop doesn't
|
24577 |
+
// appear to work on table rows at this time. Also mobile browsers are
|
24578 |
+
// not supported.
|
24579 |
+
// Use `table().container()` rather than just the table node for IE8 -
|
24580 |
+
// otherwise it only works once...
|
24581 |
+
$(dt.table().container()).on( 'mousedown.rowReorder touchstart.rowReorder', this.c.selector, function (e) {
|
24582 |
+
if ( ! that.c.enable ) {
|
24583 |
+
return;
|
24584 |
+
}
|
24585 |
+
|
24586 |
+
var tr = $(this).closest('tr');
|
24587 |
+
var row = dt.row( tr );
|
24588 |
+
|
24589 |
+
// Double check that it is a DataTable row
|
24590 |
+
if ( row.any() ) {
|
24591 |
+
that._emitEvent( 'pre-row-reorder', {
|
24592 |
+
node: row.node(),
|
24593 |
+
index: row.index()
|
24594 |
+
} );
|
24595 |
+
|
24596 |
+
that._mouseDown( e, tr );
|
24597 |
+
return false;
|
24598 |
+
}
|
24599 |
+
} );
|
24600 |
+
|
24601 |
+
dt.on( 'destroy.rowReorder', function () {
|
24602 |
+
$(dt.table().container()).off( '.rowReorder' );
|
24603 |
+
dt.off( '.rowReorder' );
|
24604 |
+
} );
|
24605 |
+
},
|
24606 |
+
|
24607 |
+
|
24608 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
24609 |
+
* Private methods
|
24610 |
+
*/
|
24611 |
+
|
24612 |
+
/**
|
24613 |
+
* Cache the measurements that RowReorder needs in the mouse move handler
|
24614 |
+
* to attempt to speed things up, rather than reading from the DOM.
|
24615 |
+
*
|
24616 |
+
* @private
|
24617 |
+
*/
|
24618 |
+
_cachePositions: function ()
|
24619 |
+
{
|
24620 |
+
var dt = this.s.dt;
|
24621 |
+
|
24622 |
+
// Frustratingly, if we add `position:relative` to the tbody, the
|
24623 |
+
// position is still relatively to the parent. So we need to adjust
|
24624 |
+
// for that
|
24625 |
+
var headerHeight = $( dt.table().node() ).find('thead').outerHeight();
|
24626 |
+
|
24627 |
+
// Need to pass the nodes through jQuery to get them in document order,
|
24628 |
+
// not what DataTables thinks it is, since we have been altering the
|
24629 |
+
// order
|
24630 |
+
var nodes = $.unique( dt.rows( { page: 'current' } ).nodes().toArray() );
|
24631 |
+
var tops = $.map( nodes, function ( node, i ) {
|
24632 |
+
return $(node).position().top - headerHeight;
|
24633 |
+
} );
|
24634 |
+
|
24635 |
+
var middles = $.map( tops, function ( top, i ) {
|
24636 |
+
return tops.length < i-1 ?
|
24637 |
+
(top + tops[i+1]) / 2 :
|
24638 |
+
(top + top + $( dt.row( ':last-child' ).node() ).outerHeight() ) / 2;
|
24639 |
+
} );
|
24640 |
+
|
24641 |
+
this.s.middles = middles;
|
24642 |
+
this.s.bodyTop = $( dt.table().body() ).offset().top;
|
24643 |
+
this.s.windowHeight = $(window).height();
|
24644 |
+
this.s.documentOuterHeight = $(document).outerHeight();
|
24645 |
+
},
|
24646 |
+
|
24647 |
+
|
24648 |
+
/**
|
24649 |
+
* Clone a row so it can be floated around the screen
|
24650 |
+
*
|
24651 |
+
* @param {jQuery} target Node to be cloned
|
24652 |
+
* @private
|
24653 |
+
*/
|
24654 |
+
_clone: function ( target )
|
24655 |
+
{
|
24656 |
+
var dt = this.s.dt;
|
24657 |
+
var clone = $( dt.table().node().cloneNode(false) )
|
24658 |
+
.addClass( 'dt-rowReorder-float' )
|
24659 |
+
.append('<tbody/>')
|
24660 |
+
.append( target.clone( false ) );
|
24661 |
+
|
24662 |
+
// Match the table and column widths - read all sizes before setting
|
24663 |
+
// to reduce reflows
|
24664 |
+
var tableWidth = target.outerWidth();
|
24665 |
+
var tableHeight = target.outerHeight();
|
24666 |
+
var sizes = target.children().map( function () {
|
24667 |
+
return $(this).width();
|
24668 |
+
} );
|
24669 |
+
|
24670 |
+
clone
|
24671 |
+
.width( tableWidth )
|
24672 |
+
.height( tableHeight )
|
24673 |
+
.find('tr').children().each( function (i) {
|
24674 |
+
this.style.width = sizes[i]+'px';
|
24675 |
+
} );
|
24676 |
+
|
24677 |
+
// Insert into the document to have it floating around
|
24678 |
+
clone.appendTo( 'body' );
|
24679 |
+
|
24680 |
+
this.dom.clone = clone;
|
24681 |
+
this.s.domCloneOuterHeight = clone.outerHeight();
|
24682 |
+
},
|
24683 |
+
|
24684 |
+
|
24685 |
+
/**
|
24686 |
+
* Update the cloned item's position in the document
|
24687 |
+
*
|
24688 |
+
* @param {object} e Event giving the mouse's position
|
24689 |
+
* @private
|
24690 |
+
*/
|
24691 |
+
_clonePosition: function ( e )
|
24692 |
+
{
|
24693 |
+
var start = this.s.start;
|
24694 |
+
var topDiff = this._eventToPage( e, 'Y' ) - start.top;
|
24695 |
+
var leftDiff = this._eventToPage( e, 'X' ) - start.left;
|
24696 |
+
var snap = this.c.snapX;
|
24697 |
+
var left;
|
24698 |
+
var top = topDiff + start.offsetTop;
|
24699 |
+
|
24700 |
+
if ( snap === true ) {
|
24701 |
+
left = start.offsetLeft;
|
24702 |
+
}
|
24703 |
+
else if ( typeof snap === 'number' ) {
|
24704 |
+
left = start.offsetLeft + snap;
|
24705 |
+
}
|
24706 |
+
else {
|
24707 |
+
left = leftDiff + start.offsetLeft;
|
24708 |
+
}
|
24709 |
+
|
24710 |
+
if(top < 0) {
|
24711 |
+
top = 0
|
24712 |
+
}
|
24713 |
+
else if(top + this.s.domCloneOuterHeight > this.s.documentOuterHeight) {
|
24714 |
+
top = this.s.documentOuterHeight - this.s.domCloneOuterHeight;
|
24715 |
+
}
|
24716 |
+
|
24717 |
+
this.dom.clone.css( {
|
24718 |
+
top: top,
|
24719 |
+
left: left
|
24720 |
+
} );
|
24721 |
+
},
|
24722 |
+
|
24723 |
+
|
24724 |
+
/**
|
24725 |
+
* Emit an event on the DataTable for listeners
|
24726 |
+
*
|
24727 |
+
* @param {string} name Event name
|
24728 |
+
* @param {array} args Event arguments
|
24729 |
+
* @private
|
24730 |
+
*/
|
24731 |
+
_emitEvent: function ( name, args )
|
24732 |
+
{
|
24733 |
+
this.s.dt.iterator( 'table', function ( ctx, i ) {
|
24734 |
+
$(ctx.nTable).triggerHandler( name+'.dt', args );
|
24735 |
+
} );
|
24736 |
+
},
|
24737 |
+
|
24738 |
+
|
24739 |
+
/**
|
24740 |
+
* Get pageX/Y position from an event, regardless of if it is a mouse or
|
24741 |
+
* touch event.
|
24742 |
+
*
|
24743 |
+
* @param {object} e Event
|
24744 |
+
* @param {string} pos X or Y (must be a capital)
|
24745 |
+
* @private
|
24746 |
+
*/
|
24747 |
+
_eventToPage: function ( e, pos )
|
24748 |
+
{
|
24749 |
+
if ( e.type.indexOf( 'touch' ) !== -1 ) {
|
24750 |
+
return e.originalEvent.touches[0][ 'page'+pos ];
|
24751 |
+
}
|
24752 |
+
|
24753 |
+
return e[ 'page'+pos ];
|
24754 |
+
},
|
24755 |
+
|
24756 |
+
|
24757 |
+
/**
|
24758 |
+
* Mouse down event handler. Read initial positions and add event handlers
|
24759 |
+
* for the move.
|
24760 |
+
*
|
24761 |
+
* @param {object} e Mouse event
|
24762 |
+
* @param {jQuery} target TR element that is to be moved
|
24763 |
+
* @private
|
24764 |
+
*/
|
24765 |
+
_mouseDown: function ( e, target )
|
24766 |
+
{
|
24767 |
+
var that = this;
|
24768 |
+
var dt = this.s.dt;
|
24769 |
+
var start = this.s.start;
|
24770 |
+
|
24771 |
+
var offset = target.offset();
|
24772 |
+
start.top = this._eventToPage( e, 'Y' );
|
24773 |
+
start.left = this._eventToPage( e, 'X' );
|
24774 |
+
start.offsetTop = offset.top;
|
24775 |
+
start.offsetLeft = offset.left;
|
24776 |
+
start.nodes = $.unique( dt.rows( { page: 'current' } ).nodes().toArray() );
|
24777 |
+
|
24778 |
+
this._cachePositions();
|
24779 |
+
this._clone( target );
|
24780 |
+
this._clonePosition( e );
|
24781 |
+
|
24782 |
+
this.dom.target = target;
|
24783 |
+
target.addClass( 'dt-rowReorder-moving' );
|
24784 |
+
|
24785 |
+
$( document )
|
24786 |
+
.on( 'mouseup.rowReorder touchend.rowReorder', function (e) {
|
24787 |
+
that._mouseUp(e);
|
24788 |
+
} )
|
24789 |
+
.on( 'mousemove.rowReorder touchmove.rowReorder', function (e) {
|
24790 |
+
that._mouseMove(e);
|
24791 |
+
} );
|
24792 |
+
|
24793 |
+
// Check if window is x-scrolling - if not, disable it for the duration
|
24794 |
+
// of the drag
|
24795 |
+
if ( $(window).width() === $(document).width() ) {
|
24796 |
+
$(document.body).addClass( 'dt-rowReorder-noOverflow' );
|
24797 |
+
}
|
24798 |
+
|
24799 |
+
// Cache scrolling information so mouse move doesn't need to read.
|
24800 |
+
// This assumes that the window and DT scroller will not change size
|
24801 |
+
// during an row drag, which I think is a fair assumption
|
24802 |
+
var scrollWrapper = this.dom.dtScroll;
|
24803 |
+
this.s.scroll = {
|
24804 |
+
windowHeight: $(window).height(),
|
24805 |
+
windowWidth: $(window).width(),
|
24806 |
+
dtTop: scrollWrapper.length ? scrollWrapper.offset().top : null,
|
24807 |
+
dtLeft: scrollWrapper.length ? scrollWrapper.offset().left : null,
|
24808 |
+
dtHeight: scrollWrapper.length ? scrollWrapper.outerHeight() : null,
|
24809 |
+
dtWidth: scrollWrapper.length ? scrollWrapper.outerWidth() : null
|
24810 |
+
};
|
24811 |
+
},
|
24812 |
+
|
24813 |
+
|
24814 |
+
/**
|
24815 |
+
* Mouse move event handler - move the cloned row and shuffle the table's
|
24816 |
+
* rows if required.
|
24817 |
+
*
|
24818 |
+
* @param {object} e Mouse event
|
24819 |
+
* @private
|
24820 |
+
*/
|
24821 |
+
_mouseMove: function ( e )
|
24822 |
+
{
|
24823 |
+
this._clonePosition( e );
|
24824 |
+
|
24825 |
+
// Transform the mouse position into a position in the table's body
|
24826 |
+
var bodyY = this._eventToPage( e, 'Y' ) - this.s.bodyTop;
|
24827 |
+
var middles = this.s.middles;
|
24828 |
+
var insertPoint = null;
|
24829 |
+
var dt = this.s.dt;
|
24830 |
+
var body = dt.table().body();
|
24831 |
+
|
24832 |
+
// Determine where the row should be inserted based on the mouse
|
24833 |
+
// position
|
24834 |
+
for ( var i=0, ien=middles.length ; i<ien ; i++ ) {
|
24835 |
+
if ( bodyY < middles[i] ) {
|
24836 |
+
insertPoint = i;
|
24837 |
+
break;
|
24838 |
+
}
|
24839 |
+
}
|
24840 |
+
|
24841 |
+
if ( insertPoint === null ) {
|
24842 |
+
insertPoint = middles.length;
|
24843 |
+
}
|
24844 |
+
|
24845 |
+
// Perform the DOM shuffle if it has changed from last time
|
24846 |
+
if ( this.s.lastInsert === null || this.s.lastInsert !== insertPoint ) {
|
24847 |
+
if ( insertPoint === 0 ) {
|
24848 |
+
this.dom.target.prependTo( body );
|
24849 |
+
}
|
24850 |
+
else {
|
24851 |
+
var nodes = $.unique( dt.rows( { page: 'current' } ).nodes().toArray() );
|
24852 |
+
|
24853 |
+
if ( insertPoint > this.s.lastInsert ) {
|
24854 |
+
this.dom.target.insertAfter( nodes[ insertPoint-1 ] );
|
24855 |
+
}
|
24856 |
+
else {
|
24857 |
+
this.dom.target.insertBefore( nodes[ insertPoint ] );
|
24858 |
+
}
|
24859 |
+
}
|
24860 |
+
|
24861 |
+
this._cachePositions();
|
24862 |
+
|
24863 |
+
this.s.lastInsert = insertPoint;
|
24864 |
+
}
|
24865 |
+
|
24866 |
+
this._shiftScroll( e );
|
24867 |
+
},
|
24868 |
+
|
24869 |
+
|
24870 |
+
/**
|
24871 |
+
* Mouse up event handler - release the event handlers and perform the
|
24872 |
+
* table updates
|
24873 |
+
*
|
24874 |
+
* @param {object} e Mouse event
|
24875 |
+
* @private
|
24876 |
+
*/
|
24877 |
+
_mouseUp: function ( e )
|
24878 |
+
{
|
24879 |
+
var that = this;
|
24880 |
+
var dt = this.s.dt;
|
24881 |
+
var i, ien;
|
24882 |
+
var dataSrc = this.c.dataSrc;
|
24883 |
+
|
24884 |
+
this.dom.clone.remove();
|
24885 |
+
this.dom.clone = null;
|
24886 |
+
|
24887 |
+
this.dom.target.removeClass( 'dt-rowReorder-moving' );
|
24888 |
+
//this.dom.target = null;
|
24889 |
+
|
24890 |
+
$(document).off( '.rowReorder' );
|
24891 |
+
$(document.body).removeClass( 'dt-rowReorder-noOverflow' );
|
24892 |
+
|
24893 |
+
clearInterval( this.s.scrollInterval );
|
24894 |
+
this.s.scrollInterval = null;
|
24895 |
+
|
24896 |
+
// Calculate the difference
|
24897 |
+
var startNodes = this.s.start.nodes;
|
24898 |
+
var endNodes = $.unique( dt.rows( { page: 'current' } ).nodes().toArray() );
|
24899 |
+
var idDiff = {};
|
24900 |
+
var fullDiff = [];
|
24901 |
+
var diffNodes = [];
|
24902 |
+
var getDataFn = this.s.getDataFn;
|
24903 |
+
var setDataFn = this.s.setDataFn;
|
24904 |
+
|
24905 |
+
for ( i=0, ien=startNodes.length ; i<ien ; i++ ) {
|
24906 |
+
if ( startNodes[i] !== endNodes[i] ) {
|
24907 |
+
var id = dt.row( endNodes[i] ).id();
|
24908 |
+
var endRowData = dt.row( endNodes[i] ).data();
|
24909 |
+
var startRowData = dt.row( startNodes[i] ).data();
|
24910 |
+
|
24911 |
+
if ( id ) {
|
24912 |
+
idDiff[ id ] = getDataFn( startRowData );
|
24913 |
+
}
|
24914 |
+
|
24915 |
+
fullDiff.push( {
|
24916 |
+
node: endNodes[i],
|
24917 |
+
oldData: getDataFn( endRowData ),
|
24918 |
+
newData: getDataFn( startRowData ),
|
24919 |
+
newPosition: i,
|
24920 |
+
oldPosition: $.inArray( endNodes[i], startNodes )
|
24921 |
+
} );
|
24922 |
+
|
24923 |
+
diffNodes.push( endNodes[i] );
|
24924 |
+
}
|
24925 |
+
}
|
24926 |
+
|
24927 |
+
// Create event args
|
24928 |
+
var eventArgs = [ fullDiff, {
|
24929 |
+
dataSrc: dataSrc,
|
24930 |
+
nodes: diffNodes,
|
24931 |
+
values: idDiff,
|
24932 |
+
triggerRow: dt.row( this.dom.target )
|
24933 |
+
} ];
|
24934 |
+
|
24935 |
+
// Emit event
|
24936 |
+
this._emitEvent( 'row-reorder', eventArgs );
|
24937 |
+
|
24938 |
+
var update = function () {
|
24939 |
+
if ( that.c.update ) {
|
24940 |
+
for ( i=0, ien=fullDiff.length ; i<ien ; i++ ) {
|
24941 |
+
var row = dt.row( fullDiff[i].node );
|
24942 |
+
var rowData = row.data();
|
24943 |
+
|
24944 |
+
setDataFn( rowData, fullDiff[i].newData );
|
24945 |
+
|
24946 |
+
// Invalidate the cell that has the same data source as the dataSrc
|
24947 |
+
dt.columns().every( function () {
|
24948 |
+
if ( this.dataSrc() === dataSrc ) {
|
24949 |
+
dt.cell( fullDiff[i].node, this.index() ).invalidate( 'data' );
|
24950 |
+
}
|
24951 |
+
} );
|
24952 |
+
}
|
24953 |
+
|
24954 |
+
// Trigger row reordered event
|
24955 |
+
that._emitEvent( 'row-reordered', eventArgs );
|
24956 |
+
|
24957 |
+
dt.draw( false );
|
24958 |
+
}
|
24959 |
+
};
|
24960 |
+
|
24961 |
+
// Editor interface
|
24962 |
+
if ( this.c.editor ) {
|
24963 |
+
// Disable user interaction while Editor is submitting
|
24964 |
+
this.c.enable = false;
|
24965 |
+
|
24966 |
+
this.c.editor
|
24967 |
+
.edit(
|
24968 |
+
diffNodes,
|
24969 |
+
false,
|
24970 |
+
$.extend( {submit: 'changed'}, this.c.formOptions )
|
24971 |
+
)
|
24972 |
+
.multiSet( dataSrc, idDiff )
|
24973 |
+
.one( 'submitUnsuccessful.rowReorder', function () {
|
24974 |
+
dt.draw( false );
|
24975 |
+
} )
|
24976 |
+
.one( 'submitSuccess.rowReorder', function () {
|
24977 |
+
update();
|
24978 |
+
} )
|
24979 |
+
.one( 'submitComplete', function () {
|
24980 |
+
that.c.enable = true;
|
24981 |
+
that.c.editor.off( '.rowReorder' );
|
24982 |
+
} )
|
24983 |
+
.submit();
|
24984 |
+
}
|
24985 |
+
else {
|
24986 |
+
update();
|
24987 |
+
}
|
24988 |
+
},
|
24989 |
+
|
24990 |
+
|
24991 |
+
/**
|
24992 |
+
* Move the window and DataTables scrolling during a drag to scroll new
|
24993 |
+
* content into view.
|
24994 |
+
*
|
24995 |
+
* This matches the `_shiftScroll` method used in AutoFill, but only
|
24996 |
+
* horizontal scrolling is considered here.
|
24997 |
+
*
|
24998 |
+
* @param {object} e Mouse move event object
|
24999 |
+
* @private
|
25000 |
+
*/
|
25001 |
+
_shiftScroll: function ( e )
|
25002 |
+
{
|
25003 |
+
var that = this;
|
25004 |
+
var dt = this.s.dt;
|
25005 |
+
var scroll = this.s.scroll;
|
25006 |
+
var runInterval = false;
|
25007 |
+
var scrollSpeed = 5;
|
25008 |
+
var buffer = 65;
|
25009 |
+
var
|
25010 |
+
windowY = e.pageY - document.body.scrollTop,
|
25011 |
+
windowVert,
|
25012 |
+
dtVert;
|
25013 |
+
|
25014 |
+
// Window calculations - based on the mouse position in the window,
|
25015 |
+
// regardless of scrolling
|
25016 |
+
if ( windowY < buffer ) {
|
25017 |
+
windowVert = scrollSpeed * -1;
|
25018 |
+
}
|
25019 |
+
else if ( windowY > scroll.windowHeight - buffer ) {
|
25020 |
+
windowVert = scrollSpeed;
|
25021 |
+
}
|
25022 |
+
|
25023 |
+
// DataTables scrolling calculations - based on the table's position in
|
25024 |
+
// the document and the mouse position on the page
|
25025 |
+
if ( scroll.dtTop !== null && e.pageY < scroll.dtTop + buffer ) {
|
25026 |
+
dtVert = scrollSpeed * -1;
|
25027 |
+
}
|
25028 |
+
else if ( scroll.dtTop !== null && e.pageY > scroll.dtTop + scroll.dtHeight - buffer ) {
|
25029 |
+
dtVert = scrollSpeed;
|
25030 |
+
}
|
25031 |
+
|
25032 |
+
// This is where it gets interesting. We want to continue scrolling
|
25033 |
+
// without requiring a mouse move, so we need an interval to be
|
25034 |
+
// triggered. The interval should continue until it is no longer needed,
|
25035 |
+
// but it must also use the latest scroll commands (for example consider
|
25036 |
+
// that the mouse might move from scrolling up to scrolling left, all
|
25037 |
+
// with the same interval running. We use the `scroll` object to "pass"
|
25038 |
+
// this information to the interval. Can't use local variables as they
|
25039 |
+
// wouldn't be the ones that are used by an already existing interval!
|
25040 |
+
if ( windowVert || dtVert ) {
|
25041 |
+
scroll.windowVert = windowVert;
|
25042 |
+
scroll.dtVert = dtVert;
|
25043 |
+
runInterval = true;
|
25044 |
+
}
|
25045 |
+
else if ( this.s.scrollInterval ) {
|
25046 |
+
// Don't need to scroll - remove any existing timer
|
25047 |
+
clearInterval( this.s.scrollInterval );
|
25048 |
+
this.s.scrollInterval = null;
|
25049 |
+
}
|
25050 |
+
|
25051 |
+
// If we need to run the interval to scroll and there is no existing
|
25052 |
+
// interval (if there is an existing one, it will continue to run)
|
25053 |
+
if ( ! this.s.scrollInterval && runInterval ) {
|
25054 |
+
this.s.scrollInterval = setInterval( function () {
|
25055 |
+
// Don't need to worry about setting scroll <0 or beyond the
|
25056 |
+
// scroll bound as the browser will just reject that.
|
25057 |
+
if ( scroll.windowVert ) {
|
25058 |
+
document.body.scrollTop += scroll.windowVert;
|
25059 |
+
}
|
25060 |
+
|
25061 |
+
// DataTables scrolling
|
25062 |
+
if ( scroll.dtVert ) {
|
25063 |
+
var scroller = that.dom.dtScroll[0];
|
25064 |
+
|
25065 |
+
if ( scroll.dtVert ) {
|
25066 |
+
scroller.scrollTop += scroll.dtVert;
|
25067 |
+
}
|
25068 |
+
}
|
25069 |
+
}, 20 );
|
25070 |
+
}
|
25071 |
+
}
|
25072 |
+
} );
|
25073 |
+
|
25074 |
+
|
25075 |
+
|
25076 |
+
/**
|
25077 |
+
* RowReorder default settings for initialisation
|
25078 |
+
*
|
25079 |
+
* @namespace
|
25080 |
+
* @name RowReorder.defaults
|
25081 |
+
* @static
|
25082 |
+
*/
|
25083 |
+
RowReorder.defaults = {
|
25084 |
+
/**
|
25085 |
+
* Data point in the host row's data source object for where to get and set
|
25086 |
+
* the data to reorder. This will normally also be the sorting column.
|
25087 |
+
*
|
25088 |
+
* @type {Number}
|
25089 |
+
*/
|
25090 |
+
dataSrc: 0,
|
25091 |
+
|
25092 |
+
/**
|
25093 |
+
* Editor instance that will be used to perform the update
|
25094 |
+
*
|
25095 |
+
* @type {DataTable.Editor}
|
25096 |
+
*/
|
25097 |
+
editor: null,
|
25098 |
+
|
25099 |
+
/**
|
25100 |
+
* Enable / disable RowReorder's user interaction
|
25101 |
+
* @type {Boolean}
|
25102 |
+
*/
|
25103 |
+
enable: true,
|
25104 |
+
|
25105 |
+
/**
|
25106 |
+
* Form options to pass to Editor when submitting a change in the row order.
|
25107 |
+
* See the Editor `from-options` object for details of the options
|
25108 |
+
* available.
|
25109 |
+
* @type {Object}
|
25110 |
+
*/
|
25111 |
+
formOptions: {},
|
25112 |
+
|
25113 |
+
/**
|
25114 |
+
* Drag handle selector. This defines the element that when dragged will
|
25115 |
+
* reorder a row.
|
25116 |
+
*
|
25117 |
+
* @type {String}
|
25118 |
+
*/
|
25119 |
+
selector: 'td:first-child',
|
25120 |
+
|
25121 |
+
/**
|
25122 |
+
* Optionally lock the dragged row's x-position. This can be `true` to
|
25123 |
+
* fix the position match the host table's, `false` to allow free movement
|
25124 |
+
* of the row, or a number to define an offset from the host table.
|
25125 |
+
*
|
25126 |
+
* @type {Boolean|number}
|
25127 |
+
*/
|
25128 |
+
snapX: false,
|
25129 |
+
|
25130 |
+
/**
|
25131 |
+
* Update the table's data on drop
|
25132 |
+
*
|
25133 |
+
* @type {Boolean}
|
25134 |
+
*/
|
25135 |
+
update: true
|
25136 |
+
};
|
25137 |
+
|
25138 |
+
|
25139 |
+
/*
|
25140 |
+
* API
|
25141 |
+
*/
|
25142 |
+
var Api = $.fn.dataTable.Api;
|
25143 |
+
|
25144 |
+
// Doesn't do anything - work around for a bug in DT... Not documented
|
25145 |
+
Api.register( 'rowReorder()', function () {
|
25146 |
+
return this;
|
25147 |
+
} );
|
25148 |
+
|
25149 |
+
Api.register( 'rowReorder.enable()', function ( toggle ) {
|
25150 |
+
if ( toggle === undefined ) {
|
25151 |
+
toggle = true;
|
25152 |
+
}
|
25153 |
+
|
25154 |
+
return this.iterator( 'table', function ( ctx ) {
|
25155 |
+
if ( ctx.rowreorder ) {
|
25156 |
+
ctx.rowreorder.c.enable = toggle;
|
25157 |
+
}
|
25158 |
+
} );
|
25159 |
+
} );
|
25160 |
+
|
25161 |
+
Api.register( 'rowReorder.disable()', function () {
|
25162 |
+
return this.iterator( 'table', function ( ctx ) {
|
25163 |
+
if ( ctx.rowreorder ) {
|
25164 |
+
ctx.rowreorder.c.enable = false;
|
25165 |
+
}
|
25166 |
+
} );
|
25167 |
+
} );
|
25168 |
+
|
25169 |
+
|
25170 |
+
/**
|
25171 |
+
* Version information
|
25172 |
+
*
|
25173 |
+
* @name RowReorder.version
|
25174 |
+
* @static
|
25175 |
+
*/
|
25176 |
+
RowReorder.version = '1.2.3';
|
25177 |
+
|
25178 |
+
|
25179 |
+
$.fn.dataTable.RowReorder = RowReorder;
|
25180 |
+
$.fn.DataTable.RowReorder = RowReorder;
|
25181 |
+
|
25182 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
25183 |
+
// events so we can automatically initialise
|
25184 |
+
$(document).on( 'init.dt.dtr', function (e, settings, json) {
|
25185 |
+
if ( e.namespace !== 'dt' ) {
|
25186 |
+
return;
|
25187 |
+
}
|
25188 |
+
|
25189 |
+
var init = settings.oInit.rowReorder;
|
25190 |
+
var defaults = DataTable.defaults.rowReorder;
|
25191 |
+
|
25192 |
+
if ( init || defaults ) {
|
25193 |
+
var opts = $.extend( {}, init, defaults );
|
25194 |
+
|
25195 |
+
if ( init !== false ) {
|
25196 |
+
new RowReorder( settings, opts );
|
25197 |
+
}
|
25198 |
+
}
|
25199 |
+
} );
|
25200 |
+
|
25201 |
+
|
25202 |
+
return RowReorder;
|
25203 |
+
}));
|
25204 |
+
|
25205 |
+
|
25206 |
+
/*! Scroller 1.4.4
|
25207 |
+
* ©2011-2018 SpryMedia Ltd - datatables.net/license
|
25208 |
+
*/
|
25209 |
+
|
25210 |
+
/**
|
25211 |
+
* @summary Scroller
|
25212 |
+
* @description Virtual rendering for DataTables
|
25213 |
+
* @version 1.4.4
|
25214 |
+
* @file dataTables.scroller.js
|
25215 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
25216 |
+
* @contact www.sprymedia.co.uk/contact
|
25217 |
+
* @copyright Copyright 2011-2018 SpryMedia Ltd.
|
25218 |
+
*
|
25219 |
+
* This source file is free software, available under the following license:
|
25220 |
+
* MIT license - http://datatables.net/license/mit
|
25221 |
+
*
|
25222 |
+
* This source file is distributed in the hope that it will be useful, but
|
25223 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
25224 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
25225 |
+
*
|
25226 |
+
* For details please refer to: http://www.datatables.net
|
25227 |
+
*/
|
25228 |
+
|
25229 |
+
(function( factory ){
|
25230 |
+
if ( typeof define === 'function' && define.amd ) {
|
25231 |
+
// AMD
|
25232 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
25233 |
+
return factory( $, window, document );
|
25234 |
+
} );
|
25235 |
+
}
|
25236 |
+
else if ( typeof exports === 'object' ) {
|
25237 |
+
// CommonJS
|
25238 |
+
module.exports = function (root, $) {
|
25239 |
+
if ( ! root ) {
|
25240 |
+
root = window;
|
25241 |
+
}
|
25242 |
+
|
25243 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
25244 |
+
$ = require('datatables.net')(root, $).$;
|
25245 |
+
}
|
25246 |
+
|
25247 |
+
return factory( $, root, root.document );
|
25248 |
+
};
|
25249 |
+
}
|
25250 |
+
else {
|
25251 |
+
// Browser
|
25252 |
+
factory( jQuery, window, document );
|
25253 |
+
}
|
25254 |
+
}(function( $, window, document, undefined ) {
|
25255 |
+
'use strict';
|
25256 |
+
var DataTable = $.fn.dataTable;
|
25257 |
+
|
25258 |
+
|
25259 |
+
/**
|
25260 |
+
* Scroller is a virtual rendering plug-in for DataTables which allows large
|
25261 |
+
* datasets to be drawn on screen every quickly. What the virtual rendering means
|
25262 |
+
* is that only the visible portion of the table (and a bit to either side to make
|
25263 |
+
* the scrolling smooth) is drawn, while the scrolling container gives the
|
25264 |
+
* visual impression that the whole table is visible. This is done by making use
|
25265 |
+
* of the pagination abilities of DataTables and moving the table around in the
|
25266 |
+
* scrolling container DataTables adds to the page. The scrolling container is
|
25267 |
+
* forced to the height it would be for the full table display using an extra
|
25268 |
+
* element.
|
25269 |
+
*
|
25270 |
+
* Note that rows in the table MUST all be the same height. Information in a cell
|
25271 |
+
* which expands on to multiple lines will cause some odd behaviour in the scrolling.
|
25272 |
+
*
|
25273 |
+
* Scroller is initialised by simply including the letter 'S' in the sDom for the
|
25274 |
+
* table you want to have this feature enabled on. Note that the 'S' must come
|
25275 |
+
* AFTER the 't' parameter in `dom`.
|
25276 |
+
*
|
25277 |
+
* Key features include:
|
25278 |
+
* <ul class="limit_length">
|
25279 |
+
* <li>Speed! The aim of Scroller for DataTables is to make rendering large data sets fast</li>
|
25280 |
+
* <li>Full compatibility with deferred rendering in DataTables for maximum speed</li>
|
25281 |
+
* <li>Display millions of rows</li>
|
25282 |
+
* <li>Integration with state saving in DataTables (scrolling position is saved)</li>
|
25283 |
+
* <li>Easy to use</li>
|
25284 |
+
* </ul>
|
25285 |
+
*
|
25286 |
+
* @class
|
25287 |
+
* @constructor
|
25288 |
+
* @global
|
25289 |
+
* @param {object} dt DataTables settings object or API instance
|
25290 |
+
* @param {object} [opts={}] Configuration object for FixedColumns. Options
|
25291 |
+
* are defined by {@link Scroller.defaults}
|
25292 |
+
*
|
25293 |
+
* @requires jQuery 1.7+
|
25294 |
+
* @requires DataTables 1.10.0+
|
25295 |
+
*
|
25296 |
+
* @example
|
25297 |
+
* $(document).ready(function() {
|
25298 |
+
* $('#example').DataTable( {
|
25299 |
+
* "scrollY": "200px",
|
25300 |
+
* "ajax": "media/dataset/large.txt",
|
25301 |
+
* "dom": "frtiS",
|
25302 |
+
* "deferRender": true
|
25303 |
+
* } );
|
25304 |
+
* } );
|
25305 |
+
*/
|
25306 |
+
var Scroller = function ( dt, opts ) {
|
25307 |
+
/* Sanity check - you just know it will happen */
|
25308 |
+
if ( ! (this instanceof Scroller) ) {
|
25309 |
+
alert( "Scroller warning: Scroller must be initialised with the 'new' keyword." );
|
25310 |
+
return;
|
25311 |
+
}
|
25312 |
+
|
25313 |
+
if ( opts === undefined ) {
|
25314 |
+
opts = {};
|
25315 |
+
}
|
25316 |
+
|
25317 |
+
/**
|
25318 |
+
* Settings object which contains customisable information for the Scroller instance
|
25319 |
+
* @namespace
|
25320 |
+
* @private
|
25321 |
+
* @extends Scroller.defaults
|
25322 |
+
*/
|
25323 |
+
this.s = {
|
25324 |
+
/**
|
25325 |
+
* DataTables settings object
|
25326 |
+
* @type object
|
25327 |
+
* @default Passed in as first parameter to constructor
|
25328 |
+
*/
|
25329 |
+
"dt": $.fn.dataTable.Api( dt ).settings()[0],
|
25330 |
+
|
25331 |
+
/**
|
25332 |
+
* Pixel location of the top of the drawn table in the viewport
|
25333 |
+
* @type int
|
25334 |
+
* @default 0
|
25335 |
+
*/
|
25336 |
+
"tableTop": 0,
|
25337 |
+
|
25338 |
+
/**
|
25339 |
+
* Pixel location of the bottom of the drawn table in the viewport
|
25340 |
+
* @type int
|
25341 |
+
* @default 0
|
25342 |
+
*/
|
25343 |
+
"tableBottom": 0,
|
25344 |
+
|
25345 |
+
/**
|
25346 |
+
* Pixel location of the boundary for when the next data set should be loaded and drawn
|
25347 |
+
* when scrolling up the way.
|
25348 |
+
* @type int
|
25349 |
+
* @default 0
|
25350 |
+
* @private
|
25351 |
+
*/
|
25352 |
+
"redrawTop": 0,
|
25353 |
+
|
25354 |
+
/**
|
25355 |
+
* Pixel location of the boundary for when the next data set should be loaded and drawn
|
25356 |
+
* when scrolling down the way. Note that this is actually calculated as the offset from
|
25357 |
+
* the top.
|
25358 |
+
* @type int
|
25359 |
+
* @default 0
|
25360 |
+
* @private
|
25361 |
+
*/
|
25362 |
+
"redrawBottom": 0,
|
25363 |
+
|
25364 |
+
/**
|
25365 |
+
* Auto row height or not indicator
|
25366 |
+
* @type bool
|
25367 |
+
* @default 0
|
25368 |
+
*/
|
25369 |
+
"autoHeight": true,
|
25370 |
+
|
25371 |
+
/**
|
25372 |
+
* Number of rows calculated as visible in the visible viewport
|
25373 |
+
* @type int
|
25374 |
+
* @default 0
|
25375 |
+
*/
|
25376 |
+
"viewportRows": 0,
|
25377 |
+
|
25378 |
+
/**
|
25379 |
+
* setTimeout reference for state saving, used when state saving is enabled in the DataTable
|
25380 |
+
* and when the user scrolls the viewport in order to stop the cookie set taking too much
|
25381 |
+
* CPU!
|
25382 |
+
* @type int
|
25383 |
+
* @default 0
|
25384 |
+
*/
|
25385 |
+
"stateTO": null,
|
25386 |
+
|
25387 |
+
/**
|
25388 |
+
* setTimeout reference for the redraw, used when server-side processing is enabled in the
|
25389 |
+
* DataTables in order to prevent DoSing the server
|
25390 |
+
* @type int
|
25391 |
+
* @default null
|
25392 |
+
*/
|
25393 |
+
"drawTO": null,
|
25394 |
+
|
25395 |
+
heights: {
|
25396 |
+
jump: null,
|
25397 |
+
page: null,
|
25398 |
+
virtual: null,
|
25399 |
+
scroll: null,
|
25400 |
+
|
25401 |
+
/**
|
25402 |
+
* Height of rows in the table
|
25403 |
+
* @type int
|
25404 |
+
* @default 0
|
25405 |
+
*/
|
25406 |
+
row: null,
|
25407 |
+
|
25408 |
+
/**
|
25409 |
+
* Pixel height of the viewport
|
25410 |
+
* @type int
|
25411 |
+
* @default 0
|
25412 |
+
*/
|
25413 |
+
viewport: null
|
25414 |
+
},
|
25415 |
+
|
25416 |
+
topRowFloat: 0,
|
25417 |
+
scrollDrawDiff: null,
|
25418 |
+
loaderVisible: false,
|
25419 |
+
forceReposition: false
|
25420 |
+
};
|
25421 |
+
|
25422 |
+
// @todo The defaults should extend a `c` property and the internal settings
|
25423 |
+
// only held in the `s` property. At the moment they are mixed
|
25424 |
+
this.s = $.extend( this.s, Scroller.oDefaults, opts );
|
25425 |
+
|
25426 |
+
// Workaround for row height being read from height object (see above comment)
|
25427 |
+
this.s.heights.row = this.s.rowHeight;
|
25428 |
+
|
25429 |
+
/**
|
25430 |
+
* DOM elements used by the class instance
|
25431 |
+
* @private
|
25432 |
+
* @namespace
|
25433 |
+
*
|
25434 |
+
*/
|
25435 |
+
this.dom = {
|
25436 |
+
"force": document.createElement('div'),
|
25437 |
+
"scroller": null,
|
25438 |
+
"table": null,
|
25439 |
+
"loader": null
|
25440 |
+
};
|
25441 |
+
|
25442 |
+
// Attach the instance to the DataTables instance so it can be accessed in
|
25443 |
+
// future. Don't initialise Scroller twice on the same table
|
25444 |
+
if ( this.s.dt.oScroller ) {
|
25445 |
+
return;
|
25446 |
+
}
|
25447 |
+
|
25448 |
+
this.s.dt.oScroller = this;
|
25449 |
+
|
25450 |
+
/* Let's do it */
|
25451 |
+
this._fnConstruct();
|
25452 |
+
};
|
25453 |
+
|
25454 |
+
|
25455 |
+
|
25456 |
+
$.extend( Scroller.prototype, {
|
25457 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
25458 |
+
* Public methods
|
25459 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
25460 |
+
|
25461 |
+
/**
|
25462 |
+
* Calculate the pixel position from the top of the scrolling container for
|
25463 |
+
* a given row
|
25464 |
+
* @param {int} iRow Row number to calculate the position of
|
25465 |
+
* @returns {int} Pixels
|
25466 |
+
* @example
|
25467 |
+
* $(document).ready(function() {
|
25468 |
+
* $('#example').dataTable( {
|
25469 |
+
* "sScrollY": "200px",
|
25470 |
+
* "sAjaxSource": "media/dataset/large.txt",
|
25471 |
+
* "sDom": "frtiS",
|
25472 |
+
* "bDeferRender": true,
|
25473 |
+
* "fnInitComplete": function (o) {
|
25474 |
+
* // Find where row 25 is
|
25475 |
+
* alert( o.oScroller.fnRowToPixels( 25 ) );
|
25476 |
+
* }
|
25477 |
+
* } );
|
25478 |
+
* } );
|
25479 |
+
*/
|
25480 |
+
"fnRowToPixels": function ( rowIdx, intParse, virtual )
|
25481 |
+
{
|
25482 |
+
var pixels;
|
25483 |
+
|
25484 |
+
if ( virtual ) {
|
25485 |
+
pixels = this._domain( 'virtualToPhysical', rowIdx * this.s.heights.row );
|
25486 |
+
}
|
25487 |
+
else {
|
25488 |
+
var diff = rowIdx - this.s.baseRowTop;
|
25489 |
+
pixels = this.s.baseScrollTop + (diff * this.s.heights.row);
|
25490 |
+
}
|
25491 |
+
|
25492 |
+
return intParse || intParse === undefined ?
|
25493 |
+
parseInt( pixels, 10 ) :
|
25494 |
+
pixels;
|
25495 |
+
},
|
25496 |
+
|
25497 |
+
|
25498 |
+
/**
|
25499 |
+
* Calculate the row number that will be found at the given pixel position
|
25500 |
+
* (y-scroll).
|
25501 |
+
*
|
25502 |
+
* Please note that when the height of the full table exceeds 1 million
|
25503 |
+
* pixels, Scroller switches into a non-linear mode for the scrollbar to fit
|
25504 |
+
* all of the records into a finite area, but this function returns a linear
|
25505 |
+
* value (relative to the last non-linear positioning).
|
25506 |
+
* @param {int} iPixels Offset from top to calculate the row number of
|
25507 |
+
* @param {int} [intParse=true] If an integer value should be returned
|
25508 |
+
* @param {int} [virtual=false] Perform the calculations in the virtual domain
|
25509 |
+
* @returns {int} Row index
|
25510 |
+
* @example
|
25511 |
+
* $(document).ready(function() {
|
25512 |
+
* $('#example').dataTable( {
|
25513 |
+
* "sScrollY": "200px",
|
25514 |
+
* "sAjaxSource": "media/dataset/large.txt",
|
25515 |
+
* "sDom": "frtiS",
|
25516 |
+
* "bDeferRender": true,
|
25517 |
+
* "fnInitComplete": function (o) {
|
25518 |
+
* // Find what row number is at 500px
|
25519 |
+
* alert( o.oScroller.fnPixelsToRow( 500 ) );
|
25520 |
+
* }
|
25521 |
+
* } );
|
25522 |
+
* } );
|
25523 |
+
*/
|
25524 |
+
"fnPixelsToRow": function ( pixels, intParse, virtual )
|
25525 |
+
{
|
25526 |
+
var diff = pixels - this.s.baseScrollTop;
|
25527 |
+
var row = virtual ?
|
25528 |
+
this._domain( 'physicalToVirtual', pixels ) / this.s.heights.row :
|
25529 |
+
( diff / this.s.heights.row ) + this.s.baseRowTop;
|
25530 |
+
|
25531 |
+
return intParse || intParse === undefined ?
|
25532 |
+
parseInt( row, 10 ) :
|
25533 |
+
row;
|
25534 |
+
},
|
25535 |
+
|
25536 |
+
|
25537 |
+
/**
|
25538 |
+
* Calculate the row number that will be found at the given pixel position (y-scroll)
|
25539 |
+
* @param {int} iRow Row index to scroll to
|
25540 |
+
* @param {bool} [bAnimate=true] Animate the transition or not
|
25541 |
+
* @returns {void}
|
25542 |
+
* @example
|
25543 |
+
* $(document).ready(function() {
|
25544 |
+
* $('#example').dataTable( {
|
25545 |
+
* "sScrollY": "200px",
|
25546 |
+
* "sAjaxSource": "media/dataset/large.txt",
|
25547 |
+
* "sDom": "frtiS",
|
25548 |
+
* "bDeferRender": true,
|
25549 |
+
* "fnInitComplete": function (o) {
|
25550 |
+
* // Immediately scroll to row 1000
|
25551 |
+
* o.oScroller.fnScrollToRow( 1000 );
|
25552 |
+
* }
|
25553 |
+
* } );
|
25554 |
+
*
|
25555 |
+
* // Sometime later on use the following to scroll to row 500...
|
25556 |
+
* var oSettings = $('#example').dataTable().fnSettings();
|
25557 |
+
* oSettings.oScroller.fnScrollToRow( 500 );
|
25558 |
+
* } );
|
25559 |
+
*/
|
25560 |
+
"fnScrollToRow": function ( iRow, bAnimate )
|
25561 |
+
{
|
25562 |
+
var that = this;
|
25563 |
+
var ani = false;
|
25564 |
+
var px = this.fnRowToPixels( iRow );
|
25565 |
+
|
25566 |
+
// We need to know if the table will redraw or not before doing the
|
25567 |
+
// scroll. If it will not redraw, then we need to use the currently
|
25568 |
+
// displayed table, and scroll with the physical pixels. Otherwise, we
|
25569 |
+
// need to calculate the table's new position from the virtual
|
25570 |
+
// transform.
|
25571 |
+
var preRows = ((this.s.displayBuffer-1)/2) * this.s.viewportRows;
|
25572 |
+
var drawRow = iRow - preRows;
|
25573 |
+
if ( drawRow < 0 ) {
|
25574 |
+
drawRow = 0;
|
25575 |
+
}
|
25576 |
+
|
25577 |
+
if ( (px > this.s.redrawBottom || px < this.s.redrawTop) && this.s.dt._iDisplayStart !== drawRow ) {
|
25578 |
+
ani = true;
|
25579 |
+
px = this.fnRowToPixels( iRow, false, true );
|
25580 |
+
|
25581 |
+
// If we need records outside the current draw region, but the new
|
25582 |
+
// scrolling position is inside that (due to the non-linear nature
|
25583 |
+
// for larger numbers of records), we need to force position update.
|
25584 |
+
if ( this.s.redrawTop < px && px < this.s.redrawBottom ) {
|
25585 |
+
this.s.forceReposition = true;
|
25586 |
+
bAnimate = false;
|
25587 |
+
}
|
25588 |
+
}
|
25589 |
+
|
25590 |
+
if ( typeof bAnimate == 'undefined' || bAnimate )
|
25591 |
+
{
|
25592 |
+
this.s.ani = ani;
|
25593 |
+
$(this.dom.scroller).animate( {
|
25594 |
+
"scrollTop": px
|
25595 |
+
}, function () {
|
25596 |
+
// This needs to happen after the animation has completed and
|
25597 |
+
// the final scroll event fired
|
25598 |
+
setTimeout( function () {
|
25599 |
+
that.s.ani = false;
|
25600 |
+
}, 25 );
|
25601 |
+
} );
|
25602 |
+
}
|
25603 |
+
else
|
25604 |
+
{
|
25605 |
+
$(this.dom.scroller).scrollTop( px );
|
25606 |
+
}
|
25607 |
+
},
|
25608 |
+
|
25609 |
+
|
25610 |
+
/**
|
25611 |
+
* Calculate and store information about how many rows are to be displayed
|
25612 |
+
* in the scrolling viewport, based on current dimensions in the browser's
|
25613 |
+
* rendering. This can be particularly useful if the table is initially
|
25614 |
+
* drawn in a hidden element - for example in a tab.
|
25615 |
+
* @param {bool} [bRedraw=true] Redraw the table automatically after the recalculation, with
|
25616 |
+
* the new dimensions forming the basis for the draw.
|
25617 |
+
* @returns {void}
|
25618 |
+
* @example
|
25619 |
+
* $(document).ready(function() {
|
25620 |
+
* // Make the example container hidden to throw off the browser's sizing
|
25621 |
+
* document.getElementById('container').style.display = "none";
|
25622 |
+
* var oTable = $('#example').dataTable( {
|
25623 |
+
* "sScrollY": "200px",
|
25624 |
+
* "sAjaxSource": "media/dataset/large.txt",
|
25625 |
+
* "sDom": "frtiS",
|
25626 |
+
* "bDeferRender": true,
|
25627 |
+
* "fnInitComplete": function (o) {
|
25628 |
+
* // Immediately scroll to row 1000
|
25629 |
+
* o.oScroller.fnScrollToRow( 1000 );
|
25630 |
+
* }
|
25631 |
+
* } );
|
25632 |
+
*
|
25633 |
+
* setTimeout( function () {
|
25634 |
+
* // Make the example container visible and recalculate the scroller sizes
|
25635 |
+
* document.getElementById('container').style.display = "block";
|
25636 |
+
* oTable.fnSettings().oScroller.fnMeasure();
|
25637 |
+
* }, 3000 );
|
25638 |
+
*/
|
25639 |
+
"fnMeasure": function ( bRedraw )
|
25640 |
+
{
|
25641 |
+
if ( this.s.autoHeight )
|
25642 |
+
{
|
25643 |
+
this._fnCalcRowHeight();
|
25644 |
+
}
|
25645 |
+
|
25646 |
+
var heights = this.s.heights;
|
25647 |
+
|
25648 |
+
if ( heights.row ) {
|
25649 |
+
heights.viewport = $.contains(document, this.dom.scroller) ?
|
25650 |
+
$(this.dom.scroller).height() :
|
25651 |
+
this._parseHeight($(this.dom.scroller).css('height'));
|
25652 |
+
|
25653 |
+
// If collapsed (no height) use the max-height parameter
|
25654 |
+
if ( ! heights.viewport ) {
|
25655 |
+
heights.viewport = this._parseHeight($(this.dom.scroller).css('max-height'));
|
25656 |
+
}
|
25657 |
+
|
25658 |
+
this.s.viewportRows = parseInt( heights.viewport / heights.row, 10 )+1;
|
25659 |
+
this.s.dt._iDisplayLength = this.s.viewportRows * this.s.displayBuffer;
|
25660 |
+
}
|
25661 |
+
|
25662 |
+
if ( bRedraw === undefined || bRedraw )
|
25663 |
+
{
|
25664 |
+
this.s.dt.oInstance.fnDraw( false );
|
25665 |
+
}
|
25666 |
+
},
|
25667 |
+
|
25668 |
+
|
25669 |
+
/**
|
25670 |
+
* Get information about current displayed record range. This corresponds to
|
25671 |
+
* the information usually displayed in the "Info" block of the table.
|
25672 |
+
*
|
25673 |
+
* @returns {object} info as an object:
|
25674 |
+
* {
|
25675 |
+
* start: {int}, // the 0-indexed record at the top of the viewport
|
25676 |
+
* end: {int}, // the 0-indexed record at the bottom of the viewport
|
25677 |
+
* }
|
25678 |
+
*/
|
25679 |
+
"fnPageInfo": function()
|
25680 |
+
{
|
25681 |
+
var
|
25682 |
+
dt = this.s.dt,
|
25683 |
+
iScrollTop = this.dom.scroller.scrollTop,
|
25684 |
+
iTotal = dt.fnRecordsDisplay(),
|
25685 |
+
iPossibleEnd = Math.ceil(this.fnPixelsToRow(iScrollTop + this.s.heights.viewport, false, this.s.ani));
|
25686 |
+
|
25687 |
+
return {
|
25688 |
+
start: Math.floor(this.fnPixelsToRow(iScrollTop, false, this.s.ani)),
|
25689 |
+
end: iTotal < iPossibleEnd ? iTotal-1 : iPossibleEnd-1
|
25690 |
+
};
|
25691 |
+
},
|
25692 |
+
|
25693 |
+
|
25694 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
25695 |
+
* Private methods (they are of course public in JS, but recommended as private)
|
25696 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
25697 |
+
|
25698 |
+
/**
|
25699 |
+
* Initialisation for Scroller
|
25700 |
+
* @returns {void}
|
25701 |
+
* @private
|
25702 |
+
*/
|
25703 |
+
"_fnConstruct": function ()
|
25704 |
+
{
|
25705 |
+
var that = this;
|
25706 |
+
|
25707 |
+
/* Sanity check */
|
25708 |
+
if ( !this.s.dt.oFeatures.bPaginate ) {
|
25709 |
+
this.s.dt.oApi._fnLog( this.s.dt, 0, 'Pagination must be enabled for Scroller' );
|
25710 |
+
return;
|
25711 |
+
}
|
25712 |
+
|
25713 |
+
/* Insert a div element that we can use to force the DT scrolling container to
|
25714 |
+
* the height that would be required if the whole table was being displayed
|
25715 |
+
*/
|
25716 |
+
this.dom.force.style.position = "relative";
|
25717 |
+
this.dom.force.style.top = "0px";
|
25718 |
+
this.dom.force.style.left = "0px";
|
25719 |
+
this.dom.force.style.width = "1px";
|
25720 |
+
|
25721 |
+
this.dom.scroller = $('div.'+this.s.dt.oClasses.sScrollBody, this.s.dt.nTableWrapper)[0];
|
25722 |
+
this.dom.scroller.appendChild( this.dom.force );
|
25723 |
+
this.dom.scroller.style.position = "relative";
|
25724 |
+
|
25725 |
+
this.dom.table = $('>table', this.dom.scroller)[0];
|
25726 |
+
this.dom.table.style.position = "absolute";
|
25727 |
+
this.dom.table.style.top = "0px";
|
25728 |
+
this.dom.table.style.left = "0px";
|
25729 |
+
|
25730 |
+
// Add class to 'announce' that we are a Scroller table
|
25731 |
+
$(this.s.dt.nTableWrapper).addClass('DTS');
|
25732 |
+
|
25733 |
+
// Add a 'loading' indicator
|
25734 |
+
if ( this.s.loadingIndicator )
|
25735 |
+
{
|
25736 |
+
this.dom.loader = $('<div class="dataTables_processing DTS_Loading">'+this.s.dt.oLanguage.sLoadingRecords+'</div>')
|
25737 |
+
.css('display', 'none');
|
25738 |
+
|
25739 |
+
$(this.dom.scroller.parentNode)
|
25740 |
+
.css('position', 'relative')
|
25741 |
+
.append( this.dom.loader );
|
25742 |
+
}
|
25743 |
+
|
25744 |
+
/* Initial size calculations */
|
25745 |
+
if ( this.s.heights.row && this.s.heights.row != 'auto' )
|
25746 |
+
{
|
25747 |
+
this.s.autoHeight = false;
|
25748 |
+
}
|
25749 |
+
this.fnMeasure( false );
|
25750 |
+
|
25751 |
+
/* Scrolling callback to see if a page change is needed - use a throttled
|
25752 |
+
* function for the save save callback so we aren't hitting it on every
|
25753 |
+
* scroll
|
25754 |
+
*/
|
25755 |
+
this.s.ingnoreScroll = true;
|
25756 |
+
this.s.stateSaveThrottle = this.s.dt.oApi._fnThrottle( function () {
|
25757 |
+
that.s.dt.oApi._fnSaveState( that.s.dt );
|
25758 |
+
}, 500 );
|
25759 |
+
$(this.dom.scroller).on( 'scroll.DTS', function (e) {
|
25760 |
+
that._fnScroll.call( that );
|
25761 |
+
} );
|
25762 |
+
|
25763 |
+
/* In iOS we catch the touchstart event in case the user tries to scroll
|
25764 |
+
* while the display is already scrolling
|
25765 |
+
*/
|
25766 |
+
$(this.dom.scroller).on('touchstart.DTS', function () {
|
25767 |
+
that._fnScroll.call( that );
|
25768 |
+
} );
|
25769 |
+
|
25770 |
+
/* Update the scroller when the DataTable is redrawn */
|
25771 |
+
this.s.dt.aoDrawCallback.push( {
|
25772 |
+
"fn": function () {
|
25773 |
+
if ( that.s.dt.bInitialised ) {
|
25774 |
+
that._fnDrawCallback.call( that );
|
25775 |
+
}
|
25776 |
+
},
|
25777 |
+
"sName": "Scroller"
|
25778 |
+
} );
|
25779 |
+
|
25780 |
+
/* On resize, update the information element, since the number of rows shown might change */
|
25781 |
+
$(window).on( 'resize.DTS', function () {
|
25782 |
+
that.fnMeasure( false );
|
25783 |
+
that._fnInfo();
|
25784 |
+
} );
|
25785 |
+
|
25786 |
+
/* Add a state saving parameter to the DT state saving so we can restore the exact
|
25787 |
+
* position of the scrolling
|
25788 |
+
*/
|
25789 |
+
var initialStateSave = true;
|
25790 |
+
this.s.dt.oApi._fnCallbackReg( this.s.dt, 'aoStateSaveParams', function (oS, oData) {
|
25791 |
+
/* Set iScroller to saved scroll position on initialization.
|
25792 |
+
*/
|
25793 |
+
if(initialStateSave && that.s.dt.oLoadedState){
|
25794 |
+
oData.iScroller = that.s.dt.oLoadedState.iScroller;
|
25795 |
+
oData.iScrollerTopRow = that.s.dt.oLoadedState.iScrollerTopRow;
|
25796 |
+
initialStateSave = false;
|
25797 |
+
} else {
|
25798 |
+
oData.iScroller = that.dom.scroller.scrollTop;
|
25799 |
+
oData.iScrollerTopRow = that.s.topRowFloat;
|
25800 |
+
}
|
25801 |
+
}, "Scroller_State" );
|
25802 |
+
|
25803 |
+
if ( this.s.dt.oLoadedState ) {
|
25804 |
+
this.s.topRowFloat = this.s.dt.oLoadedState.iScrollerTopRow || 0;
|
25805 |
+
}
|
25806 |
+
|
25807 |
+
// Measure immediately. Scroller will have been added using preInit, so
|
25808 |
+
// we can reliably do this here. We could potentially also measure on
|
25809 |
+
// init complete, which would be useful for cases where the data is Ajax
|
25810 |
+
// loaded and longer than a single line.
|
25811 |
+
$(this.s.dt.nTable).one( 'init.dt', function () {
|
25812 |
+
that.fnMeasure();
|
25813 |
+
} );
|
25814 |
+
|
25815 |
+
/* Destructor */
|
25816 |
+
this.s.dt.aoDestroyCallback.push( {
|
25817 |
+
"sName": "Scroller",
|
25818 |
+
"fn": function () {
|
25819 |
+
$(window).off( 'resize.DTS' );
|
25820 |
+
$(that.dom.scroller).off('touchstart.DTS scroll.DTS');
|
25821 |
+
$(that.s.dt.nTableWrapper).removeClass('DTS');
|
25822 |
+
$('div.DTS_Loading', that.dom.scroller.parentNode).remove();
|
25823 |
+
$(that.s.dt.nTable).off( 'init.dt' );
|
25824 |
+
|
25825 |
+
that.dom.table.style.position = "";
|
25826 |
+
that.dom.table.style.top = "";
|
25827 |
+
that.dom.table.style.left = "";
|
25828 |
+
}
|
25829 |
+
} );
|
25830 |
+
},
|
25831 |
+
|
25832 |
+
|
25833 |
+
/**
|
25834 |
+
* Scrolling function - fired whenever the scrolling position is changed.
|
25835 |
+
* This method needs to use the stored values to see if the table should be
|
25836 |
+
* redrawn as we are moving towards the end of the information that is
|
25837 |
+
* currently drawn or not. If needed, then it will redraw the table based on
|
25838 |
+
* the new position.
|
25839 |
+
* @returns {void}
|
25840 |
+
* @private
|
25841 |
+
*/
|
25842 |
+
"_fnScroll": function ()
|
25843 |
+
{
|
25844 |
+
var
|
25845 |
+
that = this,
|
25846 |
+
heights = this.s.heights,
|
25847 |
+
iScrollTop = this.dom.scroller.scrollTop,
|
25848 |
+
iTopRow;
|
25849 |
+
|
25850 |
+
if ( this.s.skip ) {
|
25851 |
+
return;
|
25852 |
+
}
|
25853 |
+
|
25854 |
+
if ( this.s.ingnoreScroll ) {
|
25855 |
+
return;
|
25856 |
+
}
|
25857 |
+
|
25858 |
+
/* If the table has been sorted or filtered, then we use the redraw that
|
25859 |
+
* DataTables as done, rather than performing our own
|
25860 |
+
*/
|
25861 |
+
if ( this.s.dt.bFiltered || this.s.dt.bSorted ) {
|
25862 |
+
this.s.lastScrollTop = 0;
|
25863 |
+
return;
|
25864 |
+
}
|
25865 |
+
|
25866 |
+
/* Update the table's information display for what is now in the viewport */
|
25867 |
+
this._fnInfo();
|
25868 |
+
|
25869 |
+
/* We don't want to state save on every scroll event - that's heavy
|
25870 |
+
* handed, so use a timeout to update the state saving only when the
|
25871 |
+
* scrolling has finished
|
25872 |
+
*/
|
25873 |
+
clearTimeout( this.s.stateTO );
|
25874 |
+
this.s.stateTO = setTimeout( function () {
|
25875 |
+
that.s.dt.oApi._fnSaveState( that.s.dt );
|
25876 |
+
}, 250 );
|
25877 |
+
|
25878 |
+
/* Check if the scroll point is outside the trigger boundary which would required
|
25879 |
+
* a DataTables redraw
|
25880 |
+
*/
|
25881 |
+
if ( this.s.forceReposition || iScrollTop < this.s.redrawTop || iScrollTop > this.s.redrawBottom ) {
|
25882 |
+
|
25883 |
+
var preRows = Math.ceil( ((this.s.displayBuffer-1)/2) * this.s.viewportRows );
|
25884 |
+
|
25885 |
+
if ( Math.abs( iScrollTop - this.s.lastScrollTop ) > heights.viewport || this.s.ani || this.s.forceReposition ) {
|
25886 |
+
iTopRow = parseInt(this._domain( 'physicalToVirtual', iScrollTop ) / heights.row, 10) - preRows;
|
25887 |
+
this.s.topRowFloat = this._domain( 'physicalToVirtual', iScrollTop ) / heights.row;
|
25888 |
+
}
|
25889 |
+
else {
|
25890 |
+
iTopRow = this.fnPixelsToRow( iScrollTop ) - preRows;
|
25891 |
+
this.s.topRowFloat = this.fnPixelsToRow( iScrollTop, false );
|
25892 |
+
}
|
25893 |
+
|
25894 |
+
this.s.forceReposition = false;
|
25895 |
+
|
25896 |
+
if ( iTopRow <= 0 ) {
|
25897 |
+
/* At the start of the table */
|
25898 |
+
iTopRow = 0;
|
25899 |
+
}
|
25900 |
+
else if ( iTopRow + this.s.dt._iDisplayLength > this.s.dt.fnRecordsDisplay() ) {
|
25901 |
+
/* At the end of the table */
|
25902 |
+
iTopRow = this.s.dt.fnRecordsDisplay() - this.s.dt._iDisplayLength;
|
25903 |
+
if ( iTopRow < 0 ) {
|
25904 |
+
iTopRow = 0;
|
25905 |
+
}
|
25906 |
+
}
|
25907 |
+
else if ( iTopRow % 2 !== 0 ) {
|
25908 |
+
// For the row-striping classes (odd/even) we want only to start
|
25909 |
+
// on evens otherwise the stripes will change between draws and
|
25910 |
+
// look rubbish
|
25911 |
+
iTopRow++;
|
25912 |
+
}
|
25913 |
+
|
25914 |
+
if ( iTopRow != this.s.dt._iDisplayStart ) {
|
25915 |
+
/* Cache the new table position for quick lookups */
|
25916 |
+
this.s.tableTop = $(this.s.dt.nTable).offset().top;
|
25917 |
+
this.s.tableBottom = $(this.s.dt.nTable).height() + this.s.tableTop;
|
25918 |
+
|
25919 |
+
var draw = function () {
|
25920 |
+
if ( that.s.scrollDrawReq === null ) {
|
25921 |
+
that.s.scrollDrawReq = iScrollTop;
|
25922 |
+
}
|
25923 |
+
|
25924 |
+
that.s.dt._iDisplayStart = iTopRow;
|
25925 |
+
that.s.dt.oApi._fnDraw( that.s.dt );
|
25926 |
+
};
|
25927 |
+
|
25928 |
+
/* Do the DataTables redraw based on the calculated start point - note that when
|
25929 |
+
* using server-side processing we introduce a small delay to not DoS the server...
|
25930 |
+
*/
|
25931 |
+
if ( this.s.dt.oFeatures.bServerSide ) {
|
25932 |
+
clearTimeout( this.s.drawTO );
|
25933 |
+
this.s.drawTO = setTimeout( draw, this.s.serverWait );
|
25934 |
+
}
|
25935 |
+
else {
|
25936 |
+
draw();
|
25937 |
+
}
|
25938 |
+
|
25939 |
+
if ( this.dom.loader && ! this.s.loaderVisible ) {
|
25940 |
+
this.dom.loader.css( 'display', 'block' );
|
25941 |
+
this.s.loaderVisible = true;
|
25942 |
+
}
|
25943 |
+
}
|
25944 |
+
}
|
25945 |
+
else {
|
25946 |
+
this.s.topRowFloat = this._domain( 'physicalToVirtual', iScrollTop ) / heights.row;
|
25947 |
+
}
|
25948 |
+
|
25949 |
+
this.s.lastScrollTop = iScrollTop;
|
25950 |
+
this.s.stateSaveThrottle();
|
25951 |
+
},
|
25952 |
+
|
25953 |
+
|
25954 |
+
/**
|
25955 |
+
* Convert from one domain to another. The physical domain is the actual
|
25956 |
+
* pixel count on the screen, while the virtual is if we had browsers which
|
25957 |
+
* had scrolling containers of infinite height (i.e. the absolute value)
|
25958 |
+
*
|
25959 |
+
* @param {string} dir Domain transform direction, `virtualToPhysical` or
|
25960 |
+
* `physicalToVirtual`
|
25961 |
+
* @returns {number} Calculated transform
|
25962 |
+
* @private
|
25963 |
+
*/
|
25964 |
+
_domain: function ( dir, val )
|
25965 |
+
{
|
25966 |
+
var heights = this.s.heights;
|
25967 |
+
var coeff;
|
25968 |
+
|
25969 |
+
// If the virtual and physical height match, then we use a linear
|
25970 |
+
// transform between the two, allowing the scrollbar to be linear
|
25971 |
+
if ( heights.virtual === heights.scroll ) {
|
25972 |
+
return val;
|
25973 |
+
}
|
25974 |
+
|
25975 |
+
// Otherwise, we want a non-linear scrollbar to take account of the
|
25976 |
+
// redrawing regions at the start and end of the table, otherwise these
|
25977 |
+
// can stutter badly - on large tables 30px (for example) scroll might
|
25978 |
+
// be hundreds of rows, so the table would be redrawing every few px at
|
25979 |
+
// the start and end. Use a simple quadratic to stop this. It does mean
|
25980 |
+
// the scrollbar is non-linear, but with such massive data sets, the
|
25981 |
+
// scrollbar is going to be a best guess anyway
|
25982 |
+
var xMax = (heights.scroll - heights.viewport) / 2;
|
25983 |
+
var yMax = (heights.virtual - heights.viewport) / 2;
|
25984 |
+
|
25985 |
+
coeff = yMax / ( xMax * xMax );
|
25986 |
+
|
25987 |
+
if ( dir === 'virtualToPhysical' ) {
|
25988 |
+
if ( val < yMax ) {
|
25989 |
+
return Math.pow(val / coeff, 0.5);
|
25990 |
+
}
|
25991 |
+
else {
|
25992 |
+
val = (yMax*2) - val;
|
25993 |
+
return val < 0 ?
|
25994 |
+
heights.scroll :
|
25995 |
+
(xMax*2) - Math.pow(val / coeff, 0.5);
|
25996 |
+
}
|
25997 |
+
}
|
25998 |
+
else if ( dir === 'physicalToVirtual' ) {
|
25999 |
+
if ( val < xMax ) {
|
26000 |
+
return val * val * coeff;
|
26001 |
+
}
|
26002 |
+
else {
|
26003 |
+
val = (xMax*2) - val;
|
26004 |
+
return val < 0 ?
|
26005 |
+
heights.virtual :
|
26006 |
+
(yMax*2) - (val * val * coeff);
|
26007 |
+
}
|
26008 |
+
}
|
26009 |
+
},
|
26010 |
+
|
26011 |
+
/**
|
26012 |
+
* Parse CSS height property string as number
|
26013 |
+
*
|
26014 |
+
* An attempt is made to parse the string as a number. Currently supported units are 'px',
|
26015 |
+
* 'vh', and 'rem'. 'em' is partially supported; it works as long as the parent element's
|
26016 |
+
* font size matches the body element. Zero is returned for unrecognized strings.
|
26017 |
+
* @param {string} cssHeight CSS height property string
|
26018 |
+
* @returns {number} height
|
26019 |
+
* @private
|
26020 |
+
*/
|
26021 |
+
_parseHeight: function(cssHeight) {
|
26022 |
+
var height;
|
26023 |
+
var matches = /^([+-]?(?:\d+(?:\.\d+)?|\.\d+))(px|em|rem|vh)$/.exec(cssHeight);
|
26024 |
+
|
26025 |
+
if (matches === null) {
|
26026 |
+
return 0;
|
26027 |
+
}
|
26028 |
+
|
26029 |
+
var value = parseFloat(matches[1]);
|
26030 |
+
var unit = matches[2];
|
26031 |
+
|
26032 |
+
if ( unit === 'px' ) {
|
26033 |
+
height = value;
|
26034 |
+
}
|
26035 |
+
else if ( unit === 'vh' ) {
|
26036 |
+
height = ( value / 100 ) * $(window).height();
|
26037 |
+
}
|
26038 |
+
else if ( unit === 'rem' ) {
|
26039 |
+
height = value * parseFloat($(':root').css('font-size'));
|
26040 |
+
}
|
26041 |
+
else if ( unit === 'em' ) {
|
26042 |
+
height = value * parseFloat($('body').css('font-size'));
|
26043 |
+
}
|
26044 |
+
|
26045 |
+
return height ?
|
26046 |
+
height :
|
26047 |
+
0;
|
26048 |
+
},
|
26049 |
+
|
26050 |
+
|
26051 |
+
/**
|
26052 |
+
* Draw callback function which is fired when the DataTable is redrawn. The main function of
|
26053 |
+
* this method is to position the drawn table correctly the scrolling container for the rows
|
26054 |
+
* that is displays as a result of the scrolling position.
|
26055 |
+
* @returns {void}
|
26056 |
+
* @private
|
26057 |
+
*/
|
26058 |
+
"_fnDrawCallback": function ()
|
26059 |
+
{
|
26060 |
+
var
|
26061 |
+
that = this,
|
26062 |
+
heights = this.s.heights,
|
26063 |
+
iScrollTop = this.dom.scroller.scrollTop,
|
26064 |
+
iActualScrollTop = iScrollTop,
|
26065 |
+
iScrollBottom = iScrollTop + heights.viewport,
|
26066 |
+
iTableHeight = $(this.s.dt.nTable).height(),
|
26067 |
+
displayStart = this.s.dt._iDisplayStart,
|
26068 |
+
displayLen = this.s.dt._iDisplayLength,
|
26069 |
+
displayEnd = this.s.dt.fnRecordsDisplay();
|
26070 |
+
|
26071 |
+
// Disable the scroll event listener while we are updating the DOM
|
26072 |
+
this.s.skip = true;
|
26073 |
+
|
26074 |
+
// Resize the scroll forcing element
|
26075 |
+
this._fnScrollForce();
|
26076 |
+
|
26077 |
+
// Reposition the scrolling for the updated virtual position if needed
|
26078 |
+
if ( displayStart === 0 ) {
|
26079 |
+
// Linear calculation at the top of the table
|
26080 |
+
iScrollTop = this.s.topRowFloat * heights.row;
|
26081 |
+
}
|
26082 |
+
else if ( displayStart + displayLen >= displayEnd ) {
|
26083 |
+
// Linear calculation that the bottom as well
|
26084 |
+
iScrollTop = heights.scroll - ((displayEnd - this.s.topRowFloat) * heights.row);
|
26085 |
+
}
|
26086 |
+
else {
|
26087 |
+
// Domain scaled in the middle
|
26088 |
+
iScrollTop = this._domain( 'virtualToPhysical', this.s.topRowFloat * heights.row );
|
26089 |
+
}
|
26090 |
+
|
26091 |
+
this.dom.scroller.scrollTop = iScrollTop;
|
26092 |
+
|
26093 |
+
// Store positional information so positional calculations can be based
|
26094 |
+
// upon the current table draw position
|
26095 |
+
this.s.baseScrollTop = iScrollTop;
|
26096 |
+
this.s.baseRowTop = this.s.topRowFloat;
|
26097 |
+
|
26098 |
+
// Position the table in the virtual scroller
|
26099 |
+
var tableTop = iScrollTop - ((this.s.topRowFloat - displayStart) * heights.row);
|
26100 |
+
if ( displayStart === 0 ) {
|
26101 |
+
tableTop = 0;
|
26102 |
+
}
|
26103 |
+
else if ( displayStart + displayLen >= displayEnd ) {
|
26104 |
+
tableTop = heights.scroll - iTableHeight;
|
26105 |
+
}
|
26106 |
+
|
26107 |
+
this.dom.table.style.top = tableTop+'px';
|
26108 |
+
|
26109 |
+
/* Cache some information for the scroller */
|
26110 |
+
this.s.tableTop = tableTop;
|
26111 |
+
this.s.tableBottom = iTableHeight + this.s.tableTop;
|
26112 |
+
|
26113 |
+
// Calculate the boundaries for where a redraw will be triggered by the
|
26114 |
+
// scroll event listener
|
26115 |
+
var boundaryPx = (iScrollTop - this.s.tableTop) * this.s.boundaryScale;
|
26116 |
+
this.s.redrawTop = iScrollTop - boundaryPx;
|
26117 |
+
this.s.redrawBottom = iScrollTop + boundaryPx > heights.scroll - heights.viewport - heights.row ?
|
26118 |
+
heights.scroll - heights.viewport - heights.row :
|
26119 |
+
iScrollTop + boundaryPx;
|
26120 |
+
|
26121 |
+
this.s.skip = false;
|
26122 |
+
|
26123 |
+
// Restore the scrolling position that was saved by DataTable's state
|
26124 |
+
// saving Note that this is done on the second draw when data is Ajax
|
26125 |
+
// sourced, and the first draw when DOM soured
|
26126 |
+
if ( this.s.dt.oFeatures.bStateSave && this.s.dt.oLoadedState !== null &&
|
26127 |
+
typeof this.s.dt.oLoadedState.iScroller != 'undefined' )
|
26128 |
+
{
|
26129 |
+
// A quirk of DataTables is that the draw callback will occur on an
|
26130 |
+
// empty set if Ajax sourced, but not if server-side processing.
|
26131 |
+
var ajaxSourced = (this.s.dt.sAjaxSource || that.s.dt.ajax) && ! this.s.dt.oFeatures.bServerSide ?
|
26132 |
+
true :
|
26133 |
+
false;
|
26134 |
+
|
26135 |
+
if ( ( ajaxSourced && this.s.dt.iDraw == 2) ||
|
26136 |
+
(!ajaxSourced && this.s.dt.iDraw == 1) )
|
26137 |
+
{
|
26138 |
+
setTimeout( function () {
|
26139 |
+
$(that.dom.scroller).scrollTop( that.s.dt.oLoadedState.iScroller );
|
26140 |
+
that.s.redrawTop = that.s.dt.oLoadedState.iScroller - (heights.viewport/2);
|
26141 |
+
|
26142 |
+
// In order to prevent layout thrashing we need another
|
26143 |
+
// small delay
|
26144 |
+
setTimeout( function () {
|
26145 |
+
that.s.ingnoreScroll = false;
|
26146 |
+
}, 0 );
|
26147 |
+
}, 0 );
|
26148 |
+
}
|
26149 |
+
}
|
26150 |
+
else {
|
26151 |
+
that.s.ingnoreScroll = false;
|
26152 |
+
}
|
26153 |
+
|
26154 |
+
// Because of the order of the DT callbacks, the info update will
|
26155 |
+
// take precedence over the one we want here. So a 'thread' break is
|
26156 |
+
// needed. Only add the thread break if bInfo is set
|
26157 |
+
if ( this.s.dt.oFeatures.bInfo ) {
|
26158 |
+
setTimeout( function () {
|
26159 |
+
that._fnInfo.call( that );
|
26160 |
+
}, 0 );
|
26161 |
+
}
|
26162 |
+
|
26163 |
+
// Hide the loading indicator
|
26164 |
+
if ( this.dom.loader && this.s.loaderVisible ) {
|
26165 |
+
this.dom.loader.css( 'display', 'none' );
|
26166 |
+
this.s.loaderVisible = false;
|
26167 |
+
}
|
26168 |
+
},
|
26169 |
+
|
26170 |
+
|
26171 |
+
/**
|
26172 |
+
* Force the scrolling container to have height beyond that of just the
|
26173 |
+
* table that has been drawn so the user can scroll the whole data set.
|
26174 |
+
*
|
26175 |
+
* Note that if the calculated required scrolling height exceeds a maximum
|
26176 |
+
* value (1 million pixels - hard-coded) the forcing element will be set
|
26177 |
+
* only to that maximum value and virtual / physical domain transforms will
|
26178 |
+
* be used to allow Scroller to display tables of any number of records.
|
26179 |
+
* @returns {void}
|
26180 |
+
* @private
|
26181 |
+
*/
|
26182 |
+
_fnScrollForce: function ()
|
26183 |
+
{
|
26184 |
+
var heights = this.s.heights;
|
26185 |
+
var max = 1000000;
|
26186 |
+
|
26187 |
+
heights.virtual = heights.row * this.s.dt.fnRecordsDisplay();
|
26188 |
+
heights.scroll = heights.virtual;
|
26189 |
+
|
26190 |
+
if ( heights.scroll > max ) {
|
26191 |
+
heights.scroll = max;
|
26192 |
+
}
|
26193 |
+
|
26194 |
+
// Minimum height so there is always a row visible (the 'no rows found'
|
26195 |
+
// if reduced to zero filtering)
|
26196 |
+
this.dom.force.style.height = heights.scroll > this.s.heights.row ?
|
26197 |
+
heights.scroll+'px' :
|
26198 |
+
this.s.heights.row+'px';
|
26199 |
+
},
|
26200 |
+
|
26201 |
+
|
26202 |
+
/**
|
26203 |
+
* Automatic calculation of table row height. This is just a little tricky here as using
|
26204 |
+
* initialisation DataTables has tale the table out of the document, so we need to create
|
26205 |
+
* a new table and insert it into the document, calculate the row height and then whip the
|
26206 |
+
* table out.
|
26207 |
+
* @returns {void}
|
26208 |
+
* @private
|
26209 |
+
*/
|
26210 |
+
"_fnCalcRowHeight": function ()
|
26211 |
+
{
|
26212 |
+
var dt = this.s.dt;
|
26213 |
+
var origTable = dt.nTable;
|
26214 |
+
var nTable = origTable.cloneNode( false );
|
26215 |
+
var tbody = $('<tbody/>').appendTo( nTable );
|
26216 |
+
var container = $(
|
26217 |
+
'<div class="'+dt.oClasses.sWrapper+' DTS">'+
|
26218 |
+
'<div class="'+dt.oClasses.sScrollWrapper+'">'+
|
26219 |
+
'<div class="'+dt.oClasses.sScrollBody+'"></div>'+
|
26220 |
+
'</div>'+
|
26221 |
+
'</div>'
|
26222 |
+
);
|
26223 |
+
|
26224 |
+
// Want 3 rows in the sizing table so :first-child and :last-child
|
26225 |
+
// CSS styles don't come into play - take the size of the middle row
|
26226 |
+
$('tbody tr:lt(4)', origTable).clone().appendTo( tbody );
|
26227 |
+
while( $('tr', tbody).length < 3 ) {
|
26228 |
+
tbody.append( '<tr><td> </td></tr>' );
|
26229 |
+
}
|
26230 |
+
|
26231 |
+
$('div.'+dt.oClasses.sScrollBody, container).append( nTable );
|
26232 |
+
|
26233 |
+
// If initialised using `dom`, use the holding element as the insert point
|
26234 |
+
var insertEl = this.s.dt.nHolding || origTable.parentNode;
|
26235 |
+
|
26236 |
+
if ( ! $(insertEl).is(':visible') ) {
|
26237 |
+
insertEl = 'body';
|
26238 |
+
}
|
26239 |
+
|
26240 |
+
container.appendTo( insertEl );
|
26241 |
+
this.s.heights.row = $('tr', tbody).eq(1).outerHeight();
|
26242 |
+
|
26243 |
+
container.remove();
|
26244 |
+
},
|
26245 |
+
|
26246 |
+
|
26247 |
+
/**
|
26248 |
+
* Update any information elements that are controlled by the DataTable based on the scrolling
|
26249 |
+
* viewport and what rows are visible in it. This function basically acts in the same way as
|
26250 |
+
* _fnUpdateInfo in DataTables, and effectively replaces that function.
|
26251 |
+
* @returns {void}
|
26252 |
+
* @private
|
26253 |
+
*/
|
26254 |
+
"_fnInfo": function ()
|
26255 |
+
{
|
26256 |
+
if ( !this.s.dt.oFeatures.bInfo )
|
26257 |
+
{
|
26258 |
+
return;
|
26259 |
+
}
|
26260 |
+
|
26261 |
+
var
|
26262 |
+
dt = this.s.dt,
|
26263 |
+
language = dt.oLanguage,
|
26264 |
+
iScrollTop = this.dom.scroller.scrollTop,
|
26265 |
+
iStart = Math.floor( this.fnPixelsToRow(iScrollTop, false, this.s.ani)+1 ),
|
26266 |
+
iMax = dt.fnRecordsTotal(),
|
26267 |
+
iTotal = dt.fnRecordsDisplay(),
|
26268 |
+
iPossibleEnd = Math.ceil( this.fnPixelsToRow(iScrollTop+this.s.heights.viewport, false, this.s.ani) ),
|
26269 |
+
iEnd = iTotal < iPossibleEnd ? iTotal : iPossibleEnd,
|
26270 |
+
sStart = dt.fnFormatNumber( iStart ),
|
26271 |
+
sEnd = dt.fnFormatNumber( iEnd ),
|
26272 |
+
sMax = dt.fnFormatNumber( iMax ),
|
26273 |
+
sTotal = dt.fnFormatNumber( iTotal ),
|
26274 |
+
sOut;
|
26275 |
+
|
26276 |
+
if ( dt.fnRecordsDisplay() === 0 &&
|
26277 |
+
dt.fnRecordsDisplay() == dt.fnRecordsTotal() )
|
26278 |
+
{
|
26279 |
+
/* Empty record set */
|
26280 |
+
sOut = language.sInfoEmpty+ language.sInfoPostFix;
|
26281 |
+
}
|
26282 |
+
else if ( dt.fnRecordsDisplay() === 0 )
|
26283 |
+
{
|
26284 |
+
/* Empty record set after filtering */
|
26285 |
+
sOut = language.sInfoEmpty +' '+
|
26286 |
+
language.sInfoFiltered.replace('_MAX_', sMax)+
|
26287 |
+
language.sInfoPostFix;
|
26288 |
+
}
|
26289 |
+
else if ( dt.fnRecordsDisplay() == dt.fnRecordsTotal() )
|
26290 |
+
{
|
26291 |
+
/* Normal record set */
|
26292 |
+
sOut = language.sInfo.
|
26293 |
+
replace('_START_', sStart).
|
26294 |
+
replace('_END_', sEnd).
|
26295 |
+
replace('_MAX_', sMax).
|
26296 |
+
replace('_TOTAL_', sTotal)+
|
26297 |
+
language.sInfoPostFix;
|
26298 |
+
}
|
26299 |
+
else
|
26300 |
+
{
|
26301 |
+
/* Record set after filtering */
|
26302 |
+
sOut = language.sInfo.
|
26303 |
+
replace('_START_', sStart).
|
26304 |
+
replace('_END_', sEnd).
|
26305 |
+
replace('_MAX_', sMax).
|
26306 |
+
replace('_TOTAL_', sTotal) +' '+
|
26307 |
+
language.sInfoFiltered.replace(
|
26308 |
+
'_MAX_',
|
26309 |
+
dt.fnFormatNumber(dt.fnRecordsTotal())
|
26310 |
+
)+
|
26311 |
+
language.sInfoPostFix;
|
26312 |
+
}
|
26313 |
+
|
26314 |
+
var callback = language.fnInfoCallback;
|
26315 |
+
if ( callback ) {
|
26316 |
+
sOut = callback.call( dt.oInstance,
|
26317 |
+
dt, iStart, iEnd, iMax, iTotal, sOut
|
26318 |
+
);
|
26319 |
+
}
|
26320 |
+
|
26321 |
+
var n = dt.aanFeatures.i;
|
26322 |
+
if ( typeof n != 'undefined' )
|
26323 |
+
{
|
26324 |
+
for ( var i=0, iLen=n.length ; i<iLen ; i++ )
|
26325 |
+
{
|
26326 |
+
$(n[i]).html( sOut );
|
26327 |
+
}
|
26328 |
+
}
|
26329 |
+
|
26330 |
+
// DT doesn't actually (yet) trigger this event, but it will in future
|
26331 |
+
$(dt.nTable).triggerHandler( 'info.dt' );
|
26332 |
+
}
|
26333 |
+
} );
|
26334 |
+
|
26335 |
+
|
26336 |
+
|
26337 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
26338 |
+
* Statics
|
26339 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
26340 |
+
|
26341 |
+
|
26342 |
+
/**
|
26343 |
+
* Scroller default settings for initialisation
|
26344 |
+
* @namespace
|
26345 |
+
* @name Scroller.defaults
|
26346 |
+
* @static
|
26347 |
+
*/
|
26348 |
+
Scroller.defaults = /** @lends Scroller.defaults */{
|
26349 |
+
/**
|
26350 |
+
* Indicate if Scroller show show trace information on the console or not. This can be
|
26351 |
+
* useful when debugging Scroller or if just curious as to what it is doing, but should
|
26352 |
+
* be turned off for production.
|
26353 |
+
* @type bool
|
26354 |
+
* @default false
|
26355 |
+
* @static
|
26356 |
+
* @example
|
26357 |
+
* var oTable = $('#example').dataTable( {
|
26358 |
+
* "sScrollY": "200px",
|
26359 |
+
* "sDom": "frtiS",
|
26360 |
+
* "bDeferRender": true,
|
26361 |
+
* "oScroller": {
|
26362 |
+
* "trace": true
|
26363 |
+
* }
|
26364 |
+
* } );
|
26365 |
+
*/
|
26366 |
+
"trace": false,
|
26367 |
+
|
26368 |
+
/**
|
26369 |
+
* Scroller will attempt to automatically calculate the height of rows for it's internal
|
26370 |
+
* calculations. However the height that is used can be overridden using this parameter.
|
26371 |
+
* @type int|string
|
26372 |
+
* @default auto
|
26373 |
+
* @static
|
26374 |
+
* @example
|
26375 |
+
* var oTable = $('#example').dataTable( {
|
26376 |
+
* "sScrollY": "200px",
|
26377 |
+
* "sDom": "frtiS",
|
26378 |
+
* "bDeferRender": true,
|
26379 |
+
* "oScroller": {
|
26380 |
+
* "rowHeight": 30
|
26381 |
+
* }
|
26382 |
+
* } );
|
26383 |
+
*/
|
26384 |
+
"rowHeight": "auto",
|
26385 |
+
|
26386 |
+
/**
|
26387 |
+
* When using server-side processing, Scroller will wait a small amount of time to allow
|
26388 |
+
* the scrolling to finish before requesting more data from the server. This prevents
|
26389 |
+
* you from DoSing your own server! The wait time can be configured by this parameter.
|
26390 |
+
* @type int
|
26391 |
+
* @default 200
|
26392 |
+
* @static
|
26393 |
+
* @example
|
26394 |
+
* var oTable = $('#example').dataTable( {
|
26395 |
+
* "sScrollY": "200px",
|
26396 |
+
* "sDom": "frtiS",
|
26397 |
+
* "bDeferRender": true,
|
26398 |
+
* "oScroller": {
|
26399 |
+
* "serverWait": 100
|
26400 |
+
* }
|
26401 |
+
* } );
|
26402 |
+
*/
|
26403 |
+
"serverWait": 200,
|
26404 |
+
|
26405 |
+
/**
|
26406 |
+
* The display buffer is what Scroller uses to calculate how many rows it should pre-fetch
|
26407 |
+
* for scrolling. Scroller automatically adjusts DataTables' display length to pre-fetch
|
26408 |
+
* rows that will be shown in "near scrolling" (i.e. just beyond the current display area).
|
26409 |
+
* The value is based upon the number of rows that can be displayed in the viewport (i.e.
|
26410 |
+
* a value of 1), and will apply the display range to records before before and after the
|
26411 |
+
* current viewport - i.e. a factor of 3 will allow Scroller to pre-fetch 1 viewport's worth
|
26412 |
+
* of rows before the current viewport, the current viewport's rows and 1 viewport's worth
|
26413 |
+
* of rows after the current viewport. Adjusting this value can be useful for ensuring
|
26414 |
+
* smooth scrolling based on your data set.
|
26415 |
+
* @type int
|
26416 |
+
* @default 7
|
26417 |
+
* @static
|
26418 |
+
* @example
|
26419 |
+
* var oTable = $('#example').dataTable( {
|
26420 |
+
* "sScrollY": "200px",
|
26421 |
+
* "sDom": "frtiS",
|
26422 |
+
* "bDeferRender": true,
|
26423 |
+
* "oScroller": {
|
26424 |
+
* "displayBuffer": 10
|
26425 |
+
* }
|
26426 |
+
* } );
|
26427 |
+
*/
|
26428 |
+
"displayBuffer": 9,
|
26429 |
+
|
26430 |
+
/**
|
26431 |
+
* Scroller uses the boundary scaling factor to decide when to redraw the table - which it
|
26432 |
+
* typically does before you reach the end of the currently loaded data set (in order to
|
26433 |
+
* allow the data to look continuous to a user scrolling through the data). If given as 0
|
26434 |
+
* then the table will be redrawn whenever the viewport is scrolled, while 1 would not
|
26435 |
+
* redraw the table until the currently loaded data has all been shown. You will want
|
26436 |
+
* something in the middle - the default factor of 0.5 is usually suitable.
|
26437 |
+
* @type float
|
26438 |
+
* @default 0.5
|
26439 |
+
* @static
|
26440 |
+
* @example
|
26441 |
+
* var oTable = $('#example').dataTable( {
|
26442 |
+
* "sScrollY": "200px",
|
26443 |
+
* "sDom": "frtiS",
|
26444 |
+
* "bDeferRender": true,
|
26445 |
+
* "oScroller": {
|
26446 |
+
* "boundaryScale": 0.75
|
26447 |
+
* }
|
26448 |
+
* } );
|
26449 |
+
*/
|
26450 |
+
"boundaryScale": 0.5,
|
26451 |
+
|
26452 |
+
/**
|
26453 |
+
* Show (or not) the loading element in the background of the table. Note that you should
|
26454 |
+
* include the dataTables.scroller.css file for this to be displayed correctly.
|
26455 |
+
* @type boolean
|
26456 |
+
* @default false
|
26457 |
+
* @static
|
26458 |
+
* @example
|
26459 |
+
* var oTable = $('#example').dataTable( {
|
26460 |
+
* "sScrollY": "200px",
|
26461 |
+
* "sDom": "frtiS",
|
26462 |
+
* "bDeferRender": true,
|
26463 |
+
* "oScroller": {
|
26464 |
+
* "loadingIndicator": true
|
26465 |
+
* }
|
26466 |
+
* } );
|
26467 |
+
*/
|
26468 |
+
"loadingIndicator": false
|
26469 |
+
};
|
26470 |
+
|
26471 |
+
Scroller.oDefaults = Scroller.defaults;
|
26472 |
+
|
26473 |
+
|
26474 |
+
|
26475 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
26476 |
+
* Constants
|
26477 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
26478 |
+
|
26479 |
+
/**
|
26480 |
+
* Scroller version
|
26481 |
+
* @type String
|
26482 |
+
* @default See code
|
26483 |
+
* @name Scroller.version
|
26484 |
+
* @static
|
26485 |
+
*/
|
26486 |
+
Scroller.version = "1.4.4";
|
26487 |
+
|
26488 |
+
|
26489 |
+
|
26490 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
26491 |
+
* Initialisation
|
26492 |
+
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
26493 |
+
|
26494 |
+
// Legacy `dom` parameter initialisation support
|
26495 |
+
if ( typeof $.fn.dataTable == "function" &&
|
26496 |
+
typeof $.fn.dataTableExt.fnVersionCheck == "function" &&
|
26497 |
+
$.fn.dataTableExt.fnVersionCheck('1.10.0') )
|
26498 |
+
{
|
26499 |
+
$.fn.dataTableExt.aoFeatures.push( {
|
26500 |
+
"fnInit": function( oDTSettings ) {
|
26501 |
+
var init = oDTSettings.oInit;
|
26502 |
+
var opts = init.scroller || init.oScroller || {};
|
26503 |
+
|
26504 |
+
new Scroller( oDTSettings, opts );
|
26505 |
+
},
|
26506 |
+
"cFeature": "S",
|
26507 |
+
"sFeature": "Scroller"
|
26508 |
+
} );
|
26509 |
+
}
|
26510 |
+
else
|
26511 |
+
{
|
26512 |
+
alert( "Warning: Scroller requires DataTables 1.10.0 or greater - www.datatables.net/download");
|
26513 |
+
}
|
26514 |
+
|
26515 |
+
// Attach a listener to the document which listens for DataTables initialisation
|
26516 |
+
// events so we can automatically initialise
|
26517 |
+
$(document).on( 'preInit.dt.dtscroller', function (e, settings) {
|
26518 |
+
if ( e.namespace !== 'dt' ) {
|
26519 |
+
return;
|
26520 |
+
}
|
26521 |
+
|
26522 |
+
var init = settings.oInit.scroller;
|
26523 |
+
var defaults = DataTable.defaults.scroller;
|
26524 |
+
|
26525 |
+
if ( init || defaults ) {
|
26526 |
+
var opts = $.extend( {}, init, defaults );
|
26527 |
+
|
26528 |
+
if ( init !== false ) {
|
26529 |
+
new Scroller( settings, opts );
|
26530 |
+
}
|
26531 |
+
}
|
26532 |
+
} );
|
26533 |
+
|
26534 |
+
|
26535 |
+
// Attach Scroller to DataTables so it can be accessed as an 'extra'
|
26536 |
+
$.fn.dataTable.Scroller = Scroller;
|
26537 |
+
$.fn.DataTable.Scroller = Scroller;
|
26538 |
+
|
26539 |
+
|
26540 |
+
// DataTables 1.10 API method aliases
|
26541 |
+
var Api = $.fn.dataTable.Api;
|
26542 |
+
|
26543 |
+
Api.register( 'scroller()', function () {
|
26544 |
+
return this;
|
26545 |
+
} );
|
26546 |
+
|
26547 |
+
// Undocumented and deprecated - is it actually useful at all?
|
26548 |
+
Api.register( 'scroller().rowToPixels()', function ( rowIdx, intParse, virtual ) {
|
26549 |
+
var ctx = this.context;
|
26550 |
+
|
26551 |
+
if ( ctx.length && ctx[0].oScroller ) {
|
26552 |
+
return ctx[0].oScroller.fnRowToPixels( rowIdx, intParse, virtual );
|
26553 |
+
}
|
26554 |
+
// undefined
|
26555 |
+
} );
|
26556 |
+
|
26557 |
+
// Undocumented and deprecated - is it actually useful at all?
|
26558 |
+
Api.register( 'scroller().pixelsToRow()', function ( pixels, intParse, virtual ) {
|
26559 |
+
var ctx = this.context;
|
26560 |
+
|
26561 |
+
if ( ctx.length && ctx[0].oScroller ) {
|
26562 |
+
return ctx[0].oScroller.fnPixelsToRow( pixels, intParse, virtual );
|
26563 |
+
}
|
26564 |
+
// undefined
|
26565 |
+
} );
|
26566 |
+
|
26567 |
+
// Undocumented and deprecated - use `row().scrollTo()` instead
|
26568 |
+
Api.register( 'scroller().scrollToRow()', function ( row, ani ) {
|
26569 |
+
this.iterator( 'table', function ( ctx ) {
|
26570 |
+
if ( ctx.oScroller ) {
|
26571 |
+
ctx.oScroller.fnScrollToRow( row, ani );
|
26572 |
+
}
|
26573 |
+
} );
|
26574 |
+
|
26575 |
+
return this;
|
26576 |
+
} );
|
26577 |
+
|
26578 |
+
Api.register( 'row().scrollTo()', function ( ani ) {
|
26579 |
+
var that = this;
|
26580 |
+
|
26581 |
+
this.iterator( 'row', function ( ctx, rowIdx ) {
|
26582 |
+
if ( ctx.oScroller ) {
|
26583 |
+
var displayIdx = that
|
26584 |
+
.rows( { order: 'applied', search: 'applied' } )
|
26585 |
+
.indexes()
|
26586 |
+
.indexOf( rowIdx );
|
26587 |
+
|
26588 |
+
ctx.oScroller.fnScrollToRow( displayIdx, ani );
|
26589 |
+
}
|
26590 |
+
} );
|
26591 |
+
|
26592 |
+
return this;
|
26593 |
+
} );
|
26594 |
+
|
26595 |
+
Api.register( 'scroller.measure()', function ( redraw ) {
|
26596 |
+
this.iterator( 'table', function ( ctx ) {
|
26597 |
+
if ( ctx.oScroller ) {
|
26598 |
+
ctx.oScroller.fnMeasure( redraw );
|
26599 |
+
}
|
26600 |
+
} );
|
26601 |
+
|
26602 |
+
return this;
|
26603 |
+
} );
|
26604 |
+
|
26605 |
+
Api.register( 'scroller.page()', function() {
|
26606 |
+
var ctx = this.context;
|
26607 |
+
|
26608 |
+
if ( ctx.length && ctx[0].oScroller ) {
|
26609 |
+
return ctx[0].oScroller.fnPageInfo();
|
26610 |
+
}
|
26611 |
+
// undefined
|
26612 |
+
} );
|
26613 |
+
|
26614 |
+
return Scroller;
|
26615 |
+
}));
|
26616 |
+
|
26617 |
+
|
26618 |
+
/*! Select for DataTables 1.2.5
|
26619 |
+
* 2015-2018 SpryMedia Ltd - datatables.net/license/mit
|
26620 |
+
*/
|
26621 |
+
|
26622 |
+
/**
|
26623 |
+
* @summary Select for DataTables
|
26624 |
+
* @description A collection of API methods, events and buttons for DataTables
|
26625 |
+
* that provides selection options of the items in a DataTable
|
26626 |
+
* @version 1.2.5
|
26627 |
+
* @file dataTables.select.js
|
26628 |
+
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
26629 |
+
* @contact datatables.net/forums
|
26630 |
+
* @copyright Copyright 2015-2018 SpryMedia Ltd.
|
26631 |
+
*
|
26632 |
+
* This source file is free software, available under the following license:
|
26633 |
+
* MIT license - http://datatables.net/license/mit
|
26634 |
+
*
|
26635 |
+
* This source file is distributed in the hope that it will be useful, but
|
26636 |
+
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
26637 |
+
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
26638 |
+
*
|
26639 |
+
* For details please refer to: http://www.datatables.net/extensions/select
|
26640 |
+
*/
|
26641 |
+
(function( factory ){
|
26642 |
+
if ( typeof define === 'function' && define.amd ) {
|
26643 |
+
// AMD
|
26644 |
+
define( ['jquery', 'datatables.net'], function ( $ ) {
|
26645 |
+
return factory( $, window, document );
|
26646 |
+
} );
|
26647 |
+
}
|
26648 |
+
else if ( typeof exports === 'object' ) {
|
26649 |
+
// CommonJS
|
26650 |
+
module.exports = function (root, $) {
|
26651 |
+
if ( ! root ) {
|
26652 |
+
root = window;
|
26653 |
+
}
|
26654 |
+
|
26655 |
+
if ( ! $ || ! $.fn.dataTable ) {
|
26656 |
+
$ = require('datatables.net')(root, $).$;
|
26657 |
+
}
|
26658 |
+
|
26659 |
+
return factory( $, root, root.document );
|
26660 |
+
};
|
26661 |
+
}
|
26662 |
+
else {
|
26663 |
+
// Browser
|
26664 |
+
factory( jQuery, window, document );
|
26665 |
+
}
|
26666 |
+
}(function( $, window, document, undefined ) {
|
26667 |
+
'use strict';
|
26668 |
+
var DataTable = $.fn.dataTable;
|
26669 |
+
|
26670 |
+
|
26671 |
+
// Version information for debugger
|
26672 |
+
DataTable.select = {};
|
26673 |
+
|
26674 |
+
DataTable.select.version = '1.2.5';
|
26675 |
+
|
26676 |
+
DataTable.select.init = function ( dt ) {
|
26677 |
+
var ctx = dt.settings()[0];
|
26678 |
+
var init = ctx.oInit.select;
|
26679 |
+
var defaults = DataTable.defaults.select;
|
26680 |
+
var opts = init === undefined ?
|
26681 |
+
defaults :
|
26682 |
+
init;
|
26683 |
+
|
26684 |
+
// Set defaults
|
26685 |
+
var items = 'row';
|
26686 |
+
var style = 'api';
|
26687 |
+
var blurable = false;
|
26688 |
+
var info = true;
|
26689 |
+
var selector = 'td, th';
|
26690 |
+
var className = 'selected';
|
26691 |
+
var setStyle = false;
|
26692 |
+
|
26693 |
+
ctx._select = {};
|
26694 |
+
|
26695 |
+
// Initialisation customisations
|
26696 |
+
if ( opts === true ) {
|
26697 |
+
style = 'os';
|
26698 |
+
setStyle = true;
|
26699 |
+
}
|
26700 |
+
else if ( typeof opts === 'string' ) {
|
26701 |
+
style = opts;
|
26702 |
+
setStyle = true;
|
26703 |
+
}
|
26704 |
+
else if ( $.isPlainObject( opts ) ) {
|
26705 |
+
if ( opts.blurable !== undefined ) {
|
26706 |
+
blurable = opts.blurable;
|
26707 |
+
}
|
26708 |
+
|
26709 |
+
if ( opts.info !== undefined ) {
|
26710 |
+
info = opts.info;
|
26711 |
+
}
|
26712 |
+
|
26713 |
+
if ( opts.items !== undefined ) {
|
26714 |
+
items = opts.items;
|
26715 |
+
}
|
26716 |
+
|
26717 |
+
if ( opts.style !== undefined ) {
|
26718 |
+
style = opts.style;
|
26719 |
+
setStyle = true;
|
26720 |
+
}
|
26721 |
+
|
26722 |
+
if ( opts.selector !== undefined ) {
|
26723 |
+
selector = opts.selector;
|
26724 |
+
}
|
26725 |
+
|
26726 |
+
if ( opts.className !== undefined ) {
|
26727 |
+
className = opts.className;
|
26728 |
+
}
|
26729 |
+
}
|
26730 |
+
|
26731 |
+
dt.select.selector( selector );
|
26732 |
+
dt.select.items( items );
|
26733 |
+
dt.select.style( style );
|
26734 |
+
dt.select.blurable( blurable );
|
26735 |
+
dt.select.info( info );
|
26736 |
+
ctx._select.className = className;
|
26737 |
+
|
26738 |
+
|
26739 |
+
// Sort table based on selected rows. Requires Select Datatables extension
|
26740 |
+
$.fn.dataTable.ext.order['select-checkbox'] = function ( settings, col ) {
|
26741 |
+
return this.api().column( col, {order: 'index'} ).nodes().map( function ( td ) {
|
26742 |
+
if ( settings._select.items === 'row' ) {
|
26743 |
+
return $( td ).parent().hasClass( settings._select.className );
|
26744 |
+
} else if ( settings._select.items === 'cell' ) {
|
26745 |
+
return $( td ).hasClass( settings._select.className );
|
26746 |
+
}
|
26747 |
+
return false;
|
26748 |
+
});
|
26749 |
+
};
|
26750 |
+
|
26751 |
+
// If the init options haven't enabled select, but there is a selectable
|
26752 |
+
// class name, then enable
|
26753 |
+
if ( ! setStyle && $( dt.table().node() ).hasClass( 'selectable' ) ) {
|
26754 |
+
dt.select.style( 'os' );
|
26755 |
+
}
|
26756 |
+
};
|
26757 |
+
|
26758 |
+
/*
|
26759 |
+
|
26760 |
+
Select is a collection of API methods, event handlers, event emitters and
|
26761 |
+
buttons (for the `Buttons` extension) for DataTables. It provides the following
|
26762 |
+
features, with an overview of how they are implemented:
|
26763 |
+
|
26764 |
+
## Selection of rows, columns and cells. Whether an item is selected or not is
|
26765 |
+
stored in:
|
26766 |
+
|
26767 |
+
* rows: a `_select_selected` property which contains a boolean value of the
|
26768 |
+
DataTables' `aoData` object for each row
|
26769 |
+
* columns: a `_select_selected` property which contains a boolean value of the
|
26770 |
+
DataTables' `aoColumns` object for each column
|
26771 |
+
* cells: a `_selected_cells` property which contains an array of boolean values
|
26772 |
+
of the `aoData` object for each row. The array is the same length as the
|
26773 |
+
columns array, with each element of it representing a cell.
|
26774 |
+
|
26775 |
+
This method of using boolean flags allows Select to operate when nodes have not
|
26776 |
+
been created for rows / cells (DataTables' defer rendering feature).
|
26777 |
+
|
26778 |
+
## API methods
|
26779 |
+
|
26780 |
+
A range of API methods are available for triggering selection and de-selection
|
26781 |
+
of rows. Methods are also available to configure the selection events that can
|
26782 |
+
be triggered by an end user (such as which items are to be selected). To a large
|
26783 |
+
extent, these of API methods *is* Select. It is basically a collection of helper
|
26784 |
+
functions that can be used to select items in a DataTable.
|
26785 |
+
|
26786 |
+
Configuration of select is held in the object `_select` which is attached to the
|
26787 |
+
DataTables settings object on initialisation. Select being available on a table
|
26788 |
+
is not optional when Select is loaded, but its default is for selection only to
|
26789 |
+
be available via the API - so the end user wouldn't be able to select rows
|
26790 |
+
without additional configuration.
|
26791 |
+
|
26792 |
+
The `_select` object contains the following properties:
|
26793 |
+
|
26794 |
+
```
|
26795 |
+
{
|
26796 |
+
items:string - Can be `rows`, `columns` or `cells`. Defines what item
|
26797 |
+
will be selected if the user is allowed to activate row
|
26798 |
+
selection using the mouse.
|
26799 |
+
style:string - Can be `none`, `single`, `multi` or `os`. Defines the
|
26800 |
+
interaction style when selecting items
|
26801 |
+
blurable:boolean - If row selection can be cleared by clicking outside of
|
26802 |
+
the table
|
26803 |
+
info:boolean - If the selection summary should be shown in the table
|
26804 |
+
information elements
|
26805 |
+
}
|
26806 |
+
```
|
26807 |
+
|
26808 |
+
In addition to the API methods, Select also extends the DataTables selector
|
26809 |
+
options for rows, columns and cells adding a `selected` option to the selector
|
26810 |
+
options object, allowing the developer to select only selected items or
|
26811 |
+
unselected items.
|
26812 |
+
|
26813 |
+
## Mouse selection of items
|
26814 |
+
|
26815 |
+
Clicking on items can be used to select items. This is done by a simple event
|
26816 |
+
handler that will select the items using the API methods.
|
26817 |
+
|
26818 |
+
*/
|
26819 |
+
|
26820 |
+
|
26821 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
26822 |
+
* Local functions
|
26823 |
+
*/
|
26824 |
+
|
26825 |
+
/**
|
26826 |
+
* Add one or more cells to the selection when shift clicking in OS selection
|
26827 |
+
* style cell selection.
|
26828 |
+
*
|
26829 |
+
* Cell range is more complicated than row and column as we want to select
|
26830 |
+
* in the visible grid rather than by index in sequence. For example, if you
|
26831 |
+
* click first in cell 1-1 and then shift click in 2-2 - cells 1-2 and 2-1
|
26832 |
+
* should also be selected (and not 1-3, 1-4. etc)
|
26833 |
+
*
|
26834 |
+
* @param {DataTable.Api} dt DataTable
|
26835 |
+
* @param {object} idx Cell index to select to
|
26836 |
+
* @param {object} last Cell index to select from
|
26837 |
+
* @private
|
26838 |
+
*/
|
26839 |
+
function cellRange( dt, idx, last )
|
26840 |
+
{
|
26841 |
+
var indexes;
|
26842 |
+
var columnIndexes;
|
26843 |
+
var rowIndexes;
|
26844 |
+
var selectColumns = function ( start, end ) {
|
26845 |
+
if ( start > end ) {
|
26846 |
+
var tmp = end;
|
26847 |
+
end = start;
|
26848 |
+
start = tmp;
|
26849 |
+
}
|
26850 |
+
|
26851 |
+
var record = false;
|
26852 |
+
return dt.columns( ':visible' ).indexes().filter( function (i) {
|
26853 |
+
if ( i === start ) {
|
26854 |
+
record = true;
|
26855 |
+
}
|
26856 |
+
|
26857 |
+
if ( i === end ) { // not else if, as start might === end
|
26858 |
+
record = false;
|
26859 |
+
return true;
|
26860 |
+
}
|
26861 |
+
|
26862 |
+
return record;
|
26863 |
+
} );
|
26864 |
+
};
|
26865 |
+
|
26866 |
+
var selectRows = function ( start, end ) {
|
26867 |
+
var indexes = dt.rows( { search: 'applied' } ).indexes();
|
26868 |
+
|
26869 |
+
// Which comes first - might need to swap
|
26870 |
+
if ( indexes.indexOf( start ) > indexes.indexOf( end ) ) {
|
26871 |
+
var tmp = end;
|
26872 |
+
end = start;
|
26873 |
+
start = tmp;
|
26874 |
+
}
|
26875 |
+
|
26876 |
+
var record = false;
|
26877 |
+
return indexes.filter( function (i) {
|
26878 |
+
if ( i === start ) {
|
26879 |
+
record = true;
|
26880 |
+
}
|
26881 |
+
|
26882 |
+
if ( i === end ) {
|
26883 |
+
record = false;
|
26884 |
+
return true;
|
26885 |
+
}
|
26886 |
+
|
26887 |
+
return record;
|
26888 |
+
} );
|
26889 |
+
};
|
26890 |
+
|
26891 |
+
if ( ! dt.cells( { selected: true } ).any() && ! last ) {
|
26892 |
+
// select from the top left cell to this one
|
26893 |
+
columnIndexes = selectColumns( 0, idx.column );
|
26894 |
+
rowIndexes = selectRows( 0 , idx.row );
|
26895 |
+
}
|
26896 |
+
else {
|
26897 |
+
// Get column indexes between old and new
|
26898 |
+
columnIndexes = selectColumns( last.column, idx.column );
|
26899 |
+
rowIndexes = selectRows( last.row , idx.row );
|
26900 |
+
}
|
26901 |
+
|
26902 |
+
indexes = dt.cells( rowIndexes, columnIndexes ).flatten();
|
26903 |
+
|
26904 |
+
if ( ! dt.cells( idx, { selected: true } ).any() ) {
|
26905 |
+
// Select range
|
26906 |
+
dt.cells( indexes ).select();
|
26907 |
+
}
|
26908 |
+
else {
|
26909 |
+
// Deselect range
|
26910 |
+
dt.cells( indexes ).deselect();
|
26911 |
+
}
|
26912 |
+
}
|
26913 |
+
|
26914 |
+
/**
|
26915 |
+
* Disable mouse selection by removing the selectors
|
26916 |
+
*
|
26917 |
+
* @param {DataTable.Api} dt DataTable to remove events from
|
26918 |
+
* @private
|
26919 |
+
*/
|
26920 |
+
function disableMouseSelection( dt )
|
26921 |
+
{
|
26922 |
+
var ctx = dt.settings()[0];
|
26923 |
+
var selector = ctx._select.selector;
|
26924 |
+
|
26925 |
+
$( dt.table().container() )
|
26926 |
+
.off( 'mousedown.dtSelect', selector )
|
26927 |
+
.off( 'mouseup.dtSelect', selector )
|
26928 |
+
.off( 'click.dtSelect', selector );
|
26929 |
+
|
26930 |
+
$('body').off( 'click.dtSelect' + dt.table().node().id );
|
26931 |
+
}
|
26932 |
+
|
26933 |
+
/**
|
26934 |
+
* Attach mouse listeners to the table to allow mouse selection of items
|
26935 |
+
*
|
26936 |
+
* @param {DataTable.Api} dt DataTable to remove events from
|
26937 |
+
* @private
|
26938 |
+
*/
|
26939 |
+
function enableMouseSelection ( dt )
|
26940 |
+
{
|
26941 |
+
var container = $( dt.table().container() );
|
26942 |
+
var ctx = dt.settings()[0];
|
26943 |
+
var selector = ctx._select.selector;
|
26944 |
+
|
26945 |
+
container
|
26946 |
+
.on( 'mousedown.dtSelect', selector, function(e) {
|
26947 |
+
// Disallow text selection for shift clicking on the table so multi
|
26948 |
+
// element selection doesn't look terrible!
|
26949 |
+
if ( e.shiftKey || e.metaKey || e.ctrlKey ) {
|
26950 |
+
container
|
26951 |
+
.css( '-moz-user-select', 'none' )
|
26952 |
+
.one('selectstart.dtSelect', selector, function () {
|
26953 |
+
return false;
|
26954 |
+
} );
|
26955 |
+
}
|
26956 |
+
} )
|
26957 |
+
.on( 'mouseup.dtSelect', selector, function() {
|
26958 |
+
// Allow text selection to occur again, Mozilla style (tested in FF
|
26959 |
+
// 35.0.1 - still required)
|
26960 |
+
container.css( '-moz-user-select', '' );
|
26961 |
+
} )
|
26962 |
+
.on( 'click.dtSelect', selector, function ( e ) {
|
26963 |
+
var items = dt.select.items();
|
26964 |
+
var idx;
|
26965 |
+
|
26966 |
+
// If text was selected (click and drag), then we shouldn't change
|
26967 |
+
// the row's selected state
|
26968 |
+
if ( window.getSelection ) {
|
26969 |
+
var selection = window.getSelection();
|
26970 |
+
|
26971 |
+
// If the element that contains the selection is not in the table, we can ignore it
|
26972 |
+
// This can happen if the developer selects text from the click event
|
26973 |
+
if ( ! selection.anchorNode || $(selection.anchorNode).closest('table')[0] === dt.table().node() ) {
|
26974 |
+
if ( $.trim(selection.toString()) !== '' ) {
|
26975 |
+
return;
|
26976 |
+
}
|
26977 |
+
}
|
26978 |
+
}
|
26979 |
+
|
26980 |
+
var ctx = dt.settings()[0];
|
26981 |
+
|
26982 |
+
// Ignore clicks inside a sub-table
|
26983 |
+
if ( $(e.target).closest('div.dataTables_wrapper')[0] != dt.table().container() ) {
|
26984 |
+
return;
|
26985 |
+
}
|
26986 |
+
|
26987 |
+
var cell = dt.cell( $(e.target).closest('td, th') );
|
26988 |
+
|
26989 |
+
// Check the cell actually belongs to the host DataTable (so child
|
26990 |
+
// rows, etc, are ignored)
|
26991 |
+
if ( ! cell.any() ) {
|
26992 |
+
return;
|
26993 |
+
}
|
26994 |
+
|
26995 |
+
var event = $.Event('user-select.dt');
|
26996 |
+
eventTrigger( dt, event, [ items, cell, e ] );
|
26997 |
+
|
26998 |
+
if ( event.isDefaultPrevented() ) {
|
26999 |
+
return;
|
27000 |
+
}
|
27001 |
+
|
27002 |
+
var cellIndex = cell.index();
|
27003 |
+
if ( items === 'row' ) {
|
27004 |
+
idx = cellIndex.row;
|
27005 |
+
typeSelect( e, dt, ctx, 'row', idx );
|
27006 |
+
}
|
27007 |
+
else if ( items === 'column' ) {
|
27008 |
+
idx = cell.index().column;
|
27009 |
+
typeSelect( e, dt, ctx, 'column', idx );
|
27010 |
+
}
|
27011 |
+
else if ( items === 'cell' ) {
|
27012 |
+
idx = cell.index();
|
27013 |
+
typeSelect( e, dt, ctx, 'cell', idx );
|
27014 |
+
}
|
27015 |
+
|
27016 |
+
ctx._select_lastCell = cellIndex;
|
27017 |
+
} );
|
27018 |
+
|
27019 |
+
// Blurable
|
27020 |
+
$('body').on( 'click.dtSelect' + dt.table().node().id, function ( e ) {
|
27021 |
+
if ( ctx._select.blurable ) {
|
27022 |
+
// If the click was inside the DataTables container, don't blur
|
27023 |
+
if ( $(e.target).parents().filter( dt.table().container() ).length ) {
|
27024 |
+
return;
|
27025 |
+
}
|
27026 |
+
|
27027 |
+
// Ignore elements which have been removed from the DOM (i.e. paging
|
27028 |
+
// buttons)
|
27029 |
+
if ( $(e.target).parents('html').length === 0 ) {
|
27030 |
+
return;
|
27031 |
+
}
|
27032 |
+
|
27033 |
+
// Don't blur in Editor form
|
27034 |
+
if ( $(e.target).parents('div.DTE').length ) {
|
27035 |
+
return;
|
27036 |
+
}
|
27037 |
+
|
27038 |
+
clear( ctx, true );
|
27039 |
+
}
|
27040 |
+
} );
|
27041 |
+
}
|
27042 |
+
|
27043 |
+
/**
|
27044 |
+
* Trigger an event on a DataTable
|
27045 |
+
*
|
27046 |
+
* @param {DataTable.Api} api DataTable to trigger events on
|
27047 |
+
* @param {boolean} selected true if selected, false if deselected
|
27048 |
+
* @param {string} type Item type acting on
|
27049 |
+
* @param {boolean} any Require that there are values before
|
27050 |
+
* triggering
|
27051 |
+
* @private
|
27052 |
+
*/
|
27053 |
+
function eventTrigger ( api, type, args, any )
|
27054 |
+
{
|
27055 |
+
if ( any && ! api.flatten().length ) {
|
27056 |
+
return;
|
27057 |
+
}
|
27058 |
+
|
27059 |
+
if ( typeof type === 'string' ) {
|
27060 |
+
type = type +'.dt';
|
27061 |
+
}
|
27062 |
+
|
27063 |
+
args.unshift( api );
|
27064 |
+
|
27065 |
+
$(api.table().node()).trigger( type, args );
|
27066 |
+
}
|
27067 |
+
|
27068 |
+
/**
|
27069 |
+
* Update the information element of the DataTable showing information about the
|
27070 |
+
* items selected. This is done by adding tags to the existing text
|
27071 |
+
*
|
27072 |
+
* @param {DataTable.Api} api DataTable to update
|
27073 |
+
* @private
|
27074 |
+
*/
|
27075 |
+
function info ( api )
|
27076 |
+
{
|
27077 |
+
var ctx = api.settings()[0];
|
27078 |
+
|
27079 |
+
if ( ! ctx._select.info || ! ctx.aanFeatures.i ) {
|
27080 |
+
return;
|
27081 |
+
}
|
27082 |
+
|
27083 |
+
if ( api.select.style() === 'api' ) {
|
27084 |
+
return;
|
27085 |
+
}
|
27086 |
+
|
27087 |
+
var rows = api.rows( { selected: true } ).flatten().length;
|
27088 |
+
var columns = api.columns( { selected: true } ).flatten().length;
|
27089 |
+
var cells = api.cells( { selected: true } ).flatten().length;
|
27090 |
+
|
27091 |
+
var add = function ( el, name, num ) {
|
27092 |
+
el.append( $('<span class="select-item"/>').append( api.i18n(
|
27093 |
+
'select.'+name+'s',
|
27094 |
+
{ _: '%d '+name+'s selected', 0: '', 1: '1 '+name+' selected' },
|
27095 |
+
num
|
27096 |
+
) ) );
|
27097 |
+
};
|
27098 |
+
|
27099 |
+
// Internal knowledge of DataTables to loop over all information elements
|
27100 |
+
$.each( ctx.aanFeatures.i, function ( i, el ) {
|
27101 |
+
el = $(el);
|
27102 |
+
|
27103 |
+
var output = $('<span class="select-info"/>');
|
27104 |
+
add( output, 'row', rows );
|
27105 |
+
add( output, 'column', columns );
|
27106 |
+
add( output, 'cell', cells );
|
27107 |
+
|
27108 |
+
var exisiting = el.children('span.select-info');
|
27109 |
+
if ( exisiting.length ) {
|
27110 |
+
exisiting.remove();
|
27111 |
+
}
|
27112 |
+
|
27113 |
+
if ( output.text() !== '' ) {
|
27114 |
+
el.append( output );
|
27115 |
+
}
|
27116 |
+
} );
|
27117 |
+
}
|
27118 |
+
|
27119 |
+
/**
|
27120 |
+
* Initialisation of a new table. Attach event handlers and callbacks to allow
|
27121 |
+
* Select to operate correctly.
|
27122 |
+
*
|
27123 |
+
* This will occur _after_ the initial DataTables initialisation, although
|
27124 |
+
* before Ajax data is rendered, if there is ajax data
|
27125 |
+
*
|
27126 |
+
* @param {DataTable.settings} ctx Settings object to operate on
|
27127 |
+
* @private
|
27128 |
+
*/
|
27129 |
+
function init ( ctx ) {
|
27130 |
+
var api = new DataTable.Api( ctx );
|
27131 |
+
|
27132 |
+
// Row callback so that classes can be added to rows and cells if the item
|
27133 |
+
// was selected before the element was created. This will happen with the
|
27134 |
+
// `deferRender` option enabled.
|
27135 |
+
//
|
27136 |
+
// This method of attaching to `aoRowCreatedCallback` is a hack until
|
27137 |
+
// DataTables has proper events for row manipulation If you are reviewing
|
27138 |
+
// this code to create your own plug-ins, please do not do this!
|
27139 |
+
ctx.aoRowCreatedCallback.push( {
|
27140 |
+
fn: function ( row, data, index ) {
|
27141 |
+
var i, ien;
|
27142 |
+
var d = ctx.aoData[ index ];
|
27143 |
+
|
27144 |
+
// Row
|
27145 |
+
if ( d._select_selected ) {
|
27146 |
+
$( row ).addClass( ctx._select.className );
|
27147 |
+
}
|
27148 |
+
|
27149 |
+
// Cells and columns - if separated out, we would need to do two
|
27150 |
+
// loops, so it makes sense to combine them into a single one
|
27151 |
+
for ( i=0, ien=ctx.aoColumns.length ; i<ien ; i++ ) {
|
27152 |
+
if ( ctx.aoColumns[i]._select_selected || (d._selected_cells && d._selected_cells[i]) ) {
|
27153 |
+
$(d.anCells[i]).addClass( ctx._select.className );
|
27154 |
+
}
|
27155 |
+
}
|
27156 |
+
},
|
27157 |
+
sName: 'select-deferRender'
|
27158 |
+
} );
|
27159 |
+
|
27160 |
+
// On Ajax reload we want to reselect all rows which are currently selected,
|
27161 |
+
// if there is an rowId (i.e. a unique value to identify each row with)
|
27162 |
+
api.on( 'preXhr.dt.dtSelect', function () {
|
27163 |
+
// note that column selection doesn't need to be cached and then
|
27164 |
+
// reselected, as they are already selected
|
27165 |
+
var rows = api.rows( { selected: true } ).ids( true ).filter( function ( d ) {
|
27166 |
+
return d !== undefined;
|
27167 |
+
} );
|
27168 |
+
|
27169 |
+
var cells = api.cells( { selected: true } ).eq(0).map( function ( cellIdx ) {
|
27170 |
+
var id = api.row( cellIdx.row ).id( true );
|
27171 |
+
return id ?
|
27172 |
+
{ row: id, column: cellIdx.column } :
|
27173 |
+
undefined;
|
27174 |
+
} ).filter( function ( d ) {
|
27175 |
+
return d !== undefined;
|
27176 |
+
} );
|
27177 |
+
|
27178 |
+
// On the next draw, reselect the currently selected items
|
27179 |
+
api.one( 'draw.dt.dtSelect', function () {
|
27180 |
+
api.rows( rows ).select();
|
27181 |
+
|
27182 |
+
// `cells` is not a cell index selector, so it needs a loop
|
27183 |
+
if ( cells.any() ) {
|
27184 |
+
cells.each( function ( id ) {
|
27185 |
+
api.cells( id.row, id.column ).select();
|
27186 |
+
} );
|
27187 |
+
}
|
27188 |
+
} );
|
27189 |
+
} );
|
27190 |
+
|
27191 |
+
// Update the table information element with selected item summary
|
27192 |
+
api.on( 'draw.dtSelect.dt select.dtSelect.dt deselect.dtSelect.dt info.dt', function () {
|
27193 |
+
info( api );
|
27194 |
+
} );
|
27195 |
+
|
27196 |
+
// Clean up and release
|
27197 |
+
api.on( 'destroy.dtSelect', function () {
|
27198 |
+
disableMouseSelection( api );
|
27199 |
+
api.off( '.dtSelect' );
|
27200 |
+
} );
|
27201 |
+
}
|
27202 |
+
|
27203 |
+
/**
|
27204 |
+
* Add one or more items (rows or columns) to the selection when shift clicking
|
27205 |
+
* in OS selection style
|
27206 |
+
*
|
27207 |
+
* @param {DataTable.Api} dt DataTable
|
27208 |
+
* @param {string} type Row or column range selector
|
27209 |
+
* @param {object} idx Item index to select to
|
27210 |
+
* @param {object} last Item index to select from
|
27211 |
+
* @private
|
27212 |
+
*/
|
27213 |
+
function rowColumnRange( dt, type, idx, last )
|
27214 |
+
{
|
27215 |
+
// Add a range of rows from the last selected row to this one
|
27216 |
+
var indexes = dt[type+'s']( { search: 'applied' } ).indexes();
|
27217 |
+
var idx1 = $.inArray( last, indexes );
|
27218 |
+
var idx2 = $.inArray( idx, indexes );
|
27219 |
+
|
27220 |
+
if ( ! dt[type+'s']( { selected: true } ).any() && idx1 === -1 ) {
|
27221 |
+
// select from top to here - slightly odd, but both Windows and Mac OS
|
27222 |
+
// do this
|
27223 |
+
indexes.splice( $.inArray( idx, indexes )+1, indexes.length );
|
27224 |
+
}
|
27225 |
+
else {
|
27226 |
+
// reverse so we can shift click 'up' as well as down
|
27227 |
+
if ( idx1 > idx2 ) {
|
27228 |
+
var tmp = idx2;
|
27229 |
+
idx2 = idx1;
|
27230 |
+
idx1 = tmp;
|
27231 |
+
}
|
27232 |
+
|
27233 |
+
indexes.splice( idx2+1, indexes.length );
|
27234 |
+
indexes.splice( 0, idx1 );
|
27235 |
+
}
|
27236 |
+
|
27237 |
+
if ( ! dt[type]( idx, { selected: true } ).any() ) {
|
27238 |
+
// Select range
|
27239 |
+
dt[type+'s']( indexes ).select();
|
27240 |
+
}
|
27241 |
+
else {
|
27242 |
+
// Deselect range - need to keep the clicked on row selected
|
27243 |
+
indexes.splice( $.inArray( idx, indexes ), 1 );
|
27244 |
+
dt[type+'s']( indexes ).deselect();
|
27245 |
+
}
|
27246 |
+
}
|
27247 |
+
|
27248 |
+
/**
|
27249 |
+
* Clear all selected items
|
27250 |
+
*
|
27251 |
+
* @param {DataTable.settings} ctx Settings object of the host DataTable
|
27252 |
+
* @param {boolean} [force=false] Force the de-selection to happen, regardless
|
27253 |
+
* of selection style
|
27254 |
+
* @private
|
27255 |
+
*/
|
27256 |
+
function clear( ctx, force )
|
27257 |
+
{
|
27258 |
+
if ( force || ctx._select.style === 'single' ) {
|
27259 |
+
var api = new DataTable.Api( ctx );
|
27260 |
+
|
27261 |
+
api.rows( { selected: true } ).deselect();
|
27262 |
+
api.columns( { selected: true } ).deselect();
|
27263 |
+
api.cells( { selected: true } ).deselect();
|
27264 |
+
}
|
27265 |
+
}
|
27266 |
+
|
27267 |
+
/**
|
27268 |
+
* Select items based on the current configuration for style and items.
|
27269 |
+
*
|
27270 |
+
* @param {object} e Mouse event object
|
27271 |
+
* @param {DataTables.Api} dt DataTable
|
27272 |
+
* @param {DataTable.settings} ctx Settings object of the host DataTable
|
27273 |
+
* @param {string} type Items to select
|
27274 |
+
* @param {int|object} idx Index of the item to select
|
27275 |
+
* @private
|
27276 |
+
*/
|
27277 |
+
function typeSelect ( e, dt, ctx, type, idx )
|
27278 |
+
{
|
27279 |
+
var style = dt.select.style();
|
27280 |
+
var isSelected = dt[type]( idx, { selected: true } ).any();
|
27281 |
+
|
27282 |
+
if ( style === 'os' ) {
|
27283 |
+
if ( e.ctrlKey || e.metaKey ) {
|
27284 |
+
// Add or remove from the selection
|
27285 |
+
dt[type]( idx ).select( ! isSelected );
|
27286 |
+
}
|
27287 |
+
else if ( e.shiftKey ) {
|
27288 |
+
if ( type === 'cell' ) {
|
27289 |
+
cellRange( dt, idx, ctx._select_lastCell || null );
|
27290 |
+
}
|
27291 |
+
else {
|
27292 |
+
rowColumnRange( dt, type, idx, ctx._select_lastCell ?
|
27293 |
+
ctx._select_lastCell[type] :
|
27294 |
+
null
|
27295 |
+
);
|
27296 |
+
}
|
27297 |
+
}
|
27298 |
+
else {
|
27299 |
+
// No cmd or shift click - deselect if selected, or select
|
27300 |
+
// this row only
|
27301 |
+
var selected = dt[type+'s']( { selected: true } );
|
27302 |
+
|
27303 |
+
if ( isSelected && selected.flatten().length === 1 ) {
|
27304 |
+
dt[type]( idx ).deselect();
|
27305 |
+
}
|
27306 |
+
else {
|
27307 |
+
selected.deselect();
|
27308 |
+
dt[type]( idx ).select();
|
27309 |
+
}
|
27310 |
+
}
|
27311 |
+
} else if ( style == 'multi+shift' ) {
|
27312 |
+
if ( e.shiftKey ) {
|
27313 |
+
if ( type === 'cell' ) {
|
27314 |
+
cellRange( dt, idx, ctx._select_lastCell || null );
|
27315 |
+
}
|
27316 |
+
else {
|
27317 |
+
rowColumnRange( dt, type, idx, ctx._select_lastCell ?
|
27318 |
+
ctx._select_lastCell[type] :
|
27319 |
+
null
|
27320 |
+
);
|
27321 |
+
}
|
27322 |
+
}
|
27323 |
+
else {
|
27324 |
+
dt[ type ]( idx ).select( ! isSelected );
|
27325 |
+
}
|
27326 |
+
}
|
27327 |
+
else {
|
27328 |
+
dt[ type ]( idx ).select( ! isSelected );
|
27329 |
+
}
|
27330 |
+
}
|
27331 |
+
|
27332 |
+
|
27333 |
+
|
27334 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
27335 |
+
* DataTables selectors
|
27336 |
+
*/
|
27337 |
+
|
27338 |
+
// row and column are basically identical just assigned to different properties
|
27339 |
+
// and checking a different array, so we can dynamically create the functions to
|
27340 |
+
// reduce the code size
|
27341 |
+
$.each( [
|
27342 |
+
{ type: 'row', prop: 'aoData' },
|
27343 |
+
{ type: 'column', prop: 'aoColumns' }
|
27344 |
+
], function ( i, o ) {
|
27345 |
+
DataTable.ext.selector[ o.type ].push( function ( settings, opts, indexes ) {
|
27346 |
+
var selected = opts.selected;
|
27347 |
+
var data;
|
27348 |
+
var out = [];
|
27349 |
+
|
27350 |
+
if ( selected !== true && selected !== false ) {
|
27351 |
+
return indexes;
|
27352 |
+
}
|
27353 |
+
|
27354 |
+
for ( var i=0, ien=indexes.length ; i<ien ; i++ ) {
|
27355 |
+
data = settings[ o.prop ][ indexes[i] ];
|
27356 |
+
|
27357 |
+
if ( (selected === true && data._select_selected === true) ||
|
27358 |
+
(selected === false && ! data._select_selected )
|
27359 |
+
) {
|
27360 |
+
out.push( indexes[i] );
|
27361 |
+
}
|
27362 |
+
}
|
27363 |
+
|
27364 |
+
return out;
|
27365 |
+
} );
|
27366 |
+
} );
|
27367 |
+
|
27368 |
+
DataTable.ext.selector.cell.push( function ( settings, opts, cells ) {
|
27369 |
+
var selected = opts.selected;
|
27370 |
+
var rowData;
|
27371 |
+
var out = [];
|
27372 |
+
|
27373 |
+
if ( selected === undefined ) {
|
27374 |
+
return cells;
|
27375 |
+
}
|
27376 |
+
|
27377 |
+
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
27378 |
+
rowData = settings.aoData[ cells[i].row ];
|
27379 |
+
|
27380 |
+
if ( (selected === true && rowData._selected_cells && rowData._selected_cells[ cells[i].column ] === true) ||
|
27381 |
+
(selected === false && ( ! rowData._selected_cells || ! rowData._selected_cells[ cells[i].column ] ) )
|
27382 |
+
) {
|
27383 |
+
out.push( cells[i] );
|
27384 |
+
}
|
27385 |
+
}
|
27386 |
+
|
27387 |
+
return out;
|
27388 |
+
} );
|
27389 |
+
|
27390 |
+
|
27391 |
+
|
27392 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
27393 |
+
* DataTables API
|
27394 |
+
*
|
27395 |
+
* For complete documentation, please refer to the docs/api directory or the
|
27396 |
+
* DataTables site
|
27397 |
+
*/
|
27398 |
+
|
27399 |
+
// Local variables to improve compression
|
27400 |
+
var apiRegister = DataTable.Api.register;
|
27401 |
+
var apiRegisterPlural = DataTable.Api.registerPlural;
|
27402 |
+
|
27403 |
+
apiRegister( 'select()', function () {
|
27404 |
+
return this.iterator( 'table', function ( ctx ) {
|
27405 |
+
DataTable.select.init( new DataTable.Api( ctx ) );
|
27406 |
+
} );
|
27407 |
+
} );
|
27408 |
+
|
27409 |
+
apiRegister( 'select.blurable()', function ( flag ) {
|
27410 |
+
if ( flag === undefined ) {
|
27411 |
+
return this.context[0]._select.blurable;
|
27412 |
+
}
|
27413 |
+
|
27414 |
+
return this.iterator( 'table', function ( ctx ) {
|
27415 |
+
ctx._select.blurable = flag;
|
27416 |
+
} );
|
27417 |
+
} );
|
27418 |
+
|
27419 |
+
apiRegister( 'select.info()', function ( flag ) {
|
27420 |
+
if ( info === undefined ) {
|
27421 |
+
return this.context[0]._select.info;
|
27422 |
+
}
|
27423 |
+
|
27424 |
+
return this.iterator( 'table', function ( ctx ) {
|
27425 |
+
ctx._select.info = flag;
|
27426 |
+
} );
|
27427 |
+
} );
|
27428 |
+
|
27429 |
+
apiRegister( 'select.items()', function ( items ) {
|
27430 |
+
if ( items === undefined ) {
|
27431 |
+
return this.context[0]._select.items;
|
27432 |
+
}
|
27433 |
+
|
27434 |
+
return this.iterator( 'table', function ( ctx ) {
|
27435 |
+
ctx._select.items = items;
|
27436 |
+
|
27437 |
+
eventTrigger( new DataTable.Api( ctx ), 'selectItems', [ items ] );
|
27438 |
+
} );
|
27439 |
+
} );
|
27440 |
+
|
27441 |
+
// Takes effect from the _next_ selection. None disables future selection, but
|
27442 |
+
// does not clear the current selection. Use the `deselect` methods for that
|
27443 |
+
apiRegister( 'select.style()', function ( style ) {
|
27444 |
+
if ( style === undefined ) {
|
27445 |
+
return this.context[0]._select.style;
|
27446 |
+
}
|
27447 |
+
|
27448 |
+
return this.iterator( 'table', function ( ctx ) {
|
27449 |
+
ctx._select.style = style;
|
27450 |
+
|
27451 |
+
if ( ! ctx._select_init ) {
|
27452 |
+
init( ctx );
|
27453 |
+
}
|
27454 |
+
|
27455 |
+
// Add / remove mouse event handlers. They aren't required when only
|
27456 |
+
// API selection is available
|
27457 |
+
var dt = new DataTable.Api( ctx );
|
27458 |
+
disableMouseSelection( dt );
|
27459 |
+
|
27460 |
+
if ( style !== 'api' ) {
|
27461 |
+
enableMouseSelection( dt );
|
27462 |
+
}
|
27463 |
+
|
27464 |
+
eventTrigger( new DataTable.Api( ctx ), 'selectStyle', [ style ] );
|
27465 |
+
} );
|
27466 |
+
} );
|
27467 |
+
|
27468 |
+
apiRegister( 'select.selector()', function ( selector ) {
|
27469 |
+
if ( selector === undefined ) {
|
27470 |
+
return this.context[0]._select.selector;
|
27471 |
+
}
|
27472 |
+
|
27473 |
+
return this.iterator( 'table', function ( ctx ) {
|
27474 |
+
disableMouseSelection( new DataTable.Api( ctx ) );
|
27475 |
+
|
27476 |
+
ctx._select.selector = selector;
|
27477 |
+
|
27478 |
+
if ( ctx._select.style !== 'api' ) {
|
27479 |
+
enableMouseSelection( new DataTable.Api( ctx ) );
|
27480 |
+
}
|
27481 |
+
} );
|
27482 |
+
} );
|
27483 |
+
|
27484 |
+
|
27485 |
+
|
27486 |
+
apiRegisterPlural( 'rows().select()', 'row().select()', function ( select ) {
|
27487 |
+
var api = this;
|
27488 |
+
|
27489 |
+
if ( select === false ) {
|
27490 |
+
return this.deselect();
|
27491 |
+
}
|
27492 |
+
|
27493 |
+
this.iterator( 'row', function ( ctx, idx ) {
|
27494 |
+
clear( ctx );
|
27495 |
+
|
27496 |
+
ctx.aoData[ idx ]._select_selected = true;
|
27497 |
+
$( ctx.aoData[ idx ].nTr ).addClass( ctx._select.className );
|
27498 |
+
} );
|
27499 |
+
|
27500 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27501 |
+
eventTrigger( api, 'select', [ 'row', api[i] ], true );
|
27502 |
+
} );
|
27503 |
+
|
27504 |
+
return this;
|
27505 |
+
} );
|
27506 |
+
|
27507 |
+
apiRegisterPlural( 'columns().select()', 'column().select()', function ( select ) {
|
27508 |
+
var api = this;
|
27509 |
+
|
27510 |
+
if ( select === false ) {
|
27511 |
+
return this.deselect();
|
27512 |
+
}
|
27513 |
+
|
27514 |
+
this.iterator( 'column', function ( ctx, idx ) {
|
27515 |
+
clear( ctx );
|
27516 |
+
|
27517 |
+
ctx.aoColumns[ idx ]._select_selected = true;
|
27518 |
+
|
27519 |
+
var column = new DataTable.Api( ctx ).column( idx );
|
27520 |
+
|
27521 |
+
$( column.header() ).addClass( ctx._select.className );
|
27522 |
+
$( column.footer() ).addClass( ctx._select.className );
|
27523 |
+
|
27524 |
+
column.nodes().to$().addClass( ctx._select.className );
|
27525 |
+
} );
|
27526 |
+
|
27527 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27528 |
+
eventTrigger( api, 'select', [ 'column', api[i] ], true );
|
27529 |
+
} );
|
27530 |
+
|
27531 |
+
return this;
|
27532 |
+
} );
|
27533 |
+
|
27534 |
+
apiRegisterPlural( 'cells().select()', 'cell().select()', function ( select ) {
|
27535 |
+
var api = this;
|
27536 |
+
|
27537 |
+
if ( select === false ) {
|
27538 |
+
return this.deselect();
|
27539 |
+
}
|
27540 |
+
|
27541 |
+
this.iterator( 'cell', function ( ctx, rowIdx, colIdx ) {
|
27542 |
+
clear( ctx );
|
27543 |
+
|
27544 |
+
var data = ctx.aoData[ rowIdx ];
|
27545 |
+
|
27546 |
+
if ( data._selected_cells === undefined ) {
|
27547 |
+
data._selected_cells = [];
|
27548 |
+
}
|
27549 |
+
|
27550 |
+
data._selected_cells[ colIdx ] = true;
|
27551 |
+
|
27552 |
+
if ( data.anCells ) {
|
27553 |
+
$( data.anCells[ colIdx ] ).addClass( ctx._select.className );
|
27554 |
+
}
|
27555 |
+
} );
|
27556 |
+
|
27557 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27558 |
+
eventTrigger( api, 'select', [ 'cell', api[i] ], true );
|
27559 |
+
} );
|
27560 |
+
|
27561 |
+
return this;
|
27562 |
+
} );
|
27563 |
+
|
27564 |
+
|
27565 |
+
apiRegisterPlural( 'rows().deselect()', 'row().deselect()', function () {
|
27566 |
+
var api = this;
|
27567 |
+
|
27568 |
+
this.iterator( 'row', function ( ctx, idx ) {
|
27569 |
+
ctx.aoData[ idx ]._select_selected = false;
|
27570 |
+
$( ctx.aoData[ idx ].nTr ).removeClass( ctx._select.className );
|
27571 |
+
} );
|
27572 |
+
|
27573 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27574 |
+
eventTrigger( api, 'deselect', [ 'row', api[i] ], true );
|
27575 |
+
} );
|
27576 |
+
|
27577 |
+
return this;
|
27578 |
+
} );
|
27579 |
+
|
27580 |
+
apiRegisterPlural( 'columns().deselect()', 'column().deselect()', function () {
|
27581 |
+
var api = this;
|
27582 |
+
|
27583 |
+
this.iterator( 'column', function ( ctx, idx ) {
|
27584 |
+
ctx.aoColumns[ idx ]._select_selected = false;
|
27585 |
+
|
27586 |
+
var api = new DataTable.Api( ctx );
|
27587 |
+
var column = api.column( idx );
|
27588 |
+
|
27589 |
+
$( column.header() ).removeClass( ctx._select.className );
|
27590 |
+
$( column.footer() ).removeClass( ctx._select.className );
|
27591 |
+
|
27592 |
+
// Need to loop over each cell, rather than just using
|
27593 |
+
// `column().nodes()` as cells which are individually selected should
|
27594 |
+
// not have the `selected` class removed from them
|
27595 |
+
api.cells( null, idx ).indexes().each( function (cellIdx) {
|
27596 |
+
var data = ctx.aoData[ cellIdx.row ];
|
27597 |
+
var cellSelected = data._selected_cells;
|
27598 |
+
|
27599 |
+
if ( data.anCells && (! cellSelected || ! cellSelected[ cellIdx.column ]) ) {
|
27600 |
+
$( data.anCells[ cellIdx.column ] ).removeClass( ctx._select.className );
|
27601 |
+
}
|
27602 |
+
} );
|
27603 |
+
} );
|
27604 |
+
|
27605 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27606 |
+
eventTrigger( api, 'deselect', [ 'column', api[i] ], true );
|
27607 |
+
} );
|
27608 |
+
|
27609 |
+
return this;
|
27610 |
+
} );
|
27611 |
+
|
27612 |
+
apiRegisterPlural( 'cells().deselect()', 'cell().deselect()', function () {
|
27613 |
+
var api = this;
|
27614 |
+
|
27615 |
+
this.iterator( 'cell', function ( ctx, rowIdx, colIdx ) {
|
27616 |
+
var data = ctx.aoData[ rowIdx ];
|
27617 |
+
|
27618 |
+
data._selected_cells[ colIdx ] = false;
|
27619 |
+
|
27620 |
+
// Remove class only if the cells exist, and the cell is not column
|
27621 |
+
// selected, in which case the class should remain (since it is selected
|
27622 |
+
// in the column)
|
27623 |
+
if ( data.anCells && ! ctx.aoColumns[ colIdx ]._select_selected ) {
|
27624 |
+
$( data.anCells[ colIdx ] ).removeClass( ctx._select.className );
|
27625 |
+
}
|
27626 |
+
} );
|
27627 |
+
|
27628 |
+
this.iterator( 'table', function ( ctx, i ) {
|
27629 |
+
eventTrigger( api, 'deselect', [ 'cell', api[i] ], true );
|
27630 |
+
} );
|
27631 |
+
|
27632 |
+
return this;
|
27633 |
+
} );
|
27634 |
+
|
27635 |
+
|
27636 |
+
|
27637 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
27638 |
+
* Buttons
|
27639 |
+
*/
|
27640 |
+
function i18n( label, def ) {
|
27641 |
+
return function (dt) {
|
27642 |
+
return dt.i18n( 'buttons.'+label, def );
|
27643 |
+
};
|
27644 |
+
}
|
27645 |
+
|
27646 |
+
// Common events with suitable namespaces
|
27647 |
+
function namespacedEvents ( config ) {
|
27648 |
+
var unique = config._eventNamespace;
|
27649 |
+
|
27650 |
+
return 'draw.dt.DT'+unique+' select.dt.DT'+unique+' deselect.dt.DT'+unique;
|
27651 |
+
}
|
27652 |
+
|
27653 |
+
function enabled ( dt, config ) {
|
27654 |
+
if ( $.inArray( 'rows', config.limitTo ) !== -1 && dt.rows( { selected: true } ).any() ) {
|
27655 |
+
return true;
|
27656 |
+
}
|
27657 |
+
|
27658 |
+
if ( $.inArray( 'columns', config.limitTo ) !== -1 && dt.columns( { selected: true } ).any() ) {
|
27659 |
+
return true;
|
27660 |
+
}
|
27661 |
+
|
27662 |
+
if ( $.inArray( 'cells', config.limitTo ) !== -1 && dt.cells( { selected: true } ).any() ) {
|
27663 |
+
return true;
|
27664 |
+
}
|
27665 |
+
|
27666 |
+
return false;
|
27667 |
+
}
|
27668 |
+
|
27669 |
+
var _buttonNamespace = 0;
|
27670 |
+
|
27671 |
+
$.extend( DataTable.ext.buttons, {
|
27672 |
+
selected: {
|
27673 |
+
text: i18n( 'selected', 'Selected' ),
|
27674 |
+
className: 'buttons-selected',
|
27675 |
+
limitTo: [ 'rows', 'columns', 'cells' ],
|
27676 |
+
init: function ( dt, node, config ) {
|
27677 |
+
var that = this;
|
27678 |
+
config._eventNamespace = '.select'+(_buttonNamespace++);
|
27679 |
+
|
27680 |
+
// .DT namespace listeners are removed by DataTables automatically
|
27681 |
+
// on table destroy
|
27682 |
+
dt.on( namespacedEvents(config), function () {
|
27683 |
+
that.enable( enabled(dt, config) );
|
27684 |
+
} );
|
27685 |
+
|
27686 |
+
this.disable();
|
27687 |
+
},
|
27688 |
+
destroy: function ( dt, node, config ) {
|
27689 |
+
dt.off( config._eventNamespace );
|
27690 |
+
}
|
27691 |
+
},
|
27692 |
+
selectedSingle: {
|
27693 |
+
text: i18n( 'selectedSingle', 'Selected single' ),
|
27694 |
+
className: 'buttons-selected-single',
|
27695 |
+
init: function ( dt, node, config ) {
|
27696 |
+
var that = this;
|
27697 |
+
config._eventNamespace = '.select'+(_buttonNamespace++);
|
27698 |
+
|
27699 |
+
dt.on( namespacedEvents(config), function () {
|
27700 |
+
var count = dt.rows( { selected: true } ).flatten().length +
|
27701 |
+
dt.columns( { selected: true } ).flatten().length +
|
27702 |
+
dt.cells( { selected: true } ).flatten().length;
|
27703 |
+
|
27704 |
+
that.enable( count === 1 );
|
27705 |
+
} );
|
27706 |
+
|
27707 |
+
this.disable();
|
27708 |
+
},
|
27709 |
+
destroy: function ( dt, node, config ) {
|
27710 |
+
dt.off( config._eventNamespace );
|
27711 |
+
}
|
27712 |
+
},
|
27713 |
+
selectAll: {
|
27714 |
+
text: i18n( 'selectAll', 'Select all' ),
|
27715 |
+
className: 'buttons-select-all',
|
27716 |
+
action: function () {
|
27717 |
+
var items = this.select.items();
|
27718 |
+
this[ items+'s' ]().select();
|
27719 |
+
}
|
27720 |
+
},
|
27721 |
+
selectNone: {
|
27722 |
+
text: i18n( 'selectNone', 'Deselect all' ),
|
27723 |
+
className: 'buttons-select-none',
|
27724 |
+
action: function () {
|
27725 |
+
clear( this.settings()[0], true );
|
27726 |
+
},
|
27727 |
+
init: function ( dt, node, config ) {
|
27728 |
+
var that = this;
|
27729 |
+
config._eventNamespace = '.select'+(_buttonNamespace++);
|
27730 |
+
|
27731 |
+
dt.on( namespacedEvents(config), function () {
|
27732 |
+
var count = dt.rows( { selected: true } ).flatten().length +
|
27733 |
+
dt.columns( { selected: true } ).flatten().length +
|
27734 |
+
dt.cells( { selected: true } ).flatten().length;
|
27735 |
+
|
27736 |
+
that.enable( count > 0 );
|
27737 |
+
} );
|
27738 |
+
|
27739 |
+
this.disable();
|
27740 |
+
},
|
27741 |
+
destroy: function ( dt, node, config ) {
|
27742 |
+
dt.off( config._eventNamespace );
|
27743 |
+
}
|
27744 |
+
}
|
27745 |
+
} );
|
27746 |
+
|
27747 |
+
$.each( [ 'Row', 'Column', 'Cell' ], function ( i, item ) {
|
27748 |
+
var lc = item.toLowerCase();
|
27749 |
+
|
27750 |
+
DataTable.ext.buttons[ 'select'+item+'s' ] = {
|
27751 |
+
text: i18n( 'select'+item+'s', 'Select '+lc+'s' ),
|
27752 |
+
className: 'buttons-select-'+lc+'s',
|
27753 |
+
action: function () {
|
27754 |
+
this.select.items( lc );
|
27755 |
+
},
|
27756 |
+
init: function ( dt ) {
|
27757 |
+
var that = this;
|
27758 |
+
|
27759 |
+
dt.on( 'selectItems.dt.DT', function ( e, ctx, items ) {
|
27760 |
+
that.active( items === lc );
|
27761 |
+
} );
|
27762 |
+
}
|
27763 |
+
};
|
27764 |
+
} );
|
27765 |
+
|
27766 |
+
|
27767 |
+
|
27768 |
+
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
27769 |
+
* Initialisation
|
27770 |
+
*/
|
27771 |
+
|
27772 |
+
// DataTables creation - check if select has been defined in the options. Note
|
27773 |
+
// this required that the table be in the document! If it isn't then something
|
27774 |
+
// needs to trigger this method unfortunately. The next major release of
|
27775 |
+
// DataTables will rework the events and address this.
|
27776 |
+
$(document).on( 'preInit.dt.dtSelect', function (e, ctx) {
|
27777 |
+
if ( e.namespace !== 'dt' ) {
|
27778 |
+
return;
|
27779 |
+
}
|
27780 |
+
|
27781 |
+
DataTable.select.init( new DataTable.Api( ctx ) );
|
27782 |
+
} );
|
27783 |
+
|
27784 |
+
|
27785 |
+
return DataTable.select;
|
27786 |
+
}));
|
27787 |
+
|
27788 |
+
|
common/vendor/datatables/datatables.min.css
ADDED
@@ -0,0 +1,136 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* This combined file was created by the DataTables downloader builder:
|
3 |
+
* https://datatables.net/download
|
4 |
+
*
|
5 |
+
* To rebuild or modify this file with the latest versions of the included
|
6 |
+
* software please visit:
|
7 |
+
* https://datatables.net/download/#dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5
|
8 |
+
*
|
9 |
+
* Included libraries:
|
10 |
+
* DataTables 1.10.16, AutoFill 2.2.2, Buttons 1.5.1, ColReorder 1.4.1, FixedColumns 3.2.4, FixedHeader 3.1.3, KeyTable 2.3.2, Responsive 2.2.1, RowReorder 1.2.3, Scroller 1.4.4, Select 1.2.5
|
11 |
+
*/
|
12 |
+
|
13 |
+
table.dataTable{width:100%;margin:0 auto;clear:both;border-collapse:separate;border-spacing:0}table.dataTable thead th,table.dataTable tfoot th{font-weight:bold}table.dataTable thead th,table.dataTable thead td{padding:10px 18px;border-bottom:1px solid #111}table.dataTable thead th:active,table.dataTable thead td:active{outline:none}table.dataTable tfoot th,table.dataTable tfoot td{padding:10px 18px 6px 18px;border-top:1px solid #111}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_desc,table.dataTable thead .sorting_asc_disabled,table.dataTable thead .sorting_desc_disabled{cursor:pointer;*cursor:hand;background-repeat:no-repeat;background-position:center right}table.dataTable thead .sorting{background-image:url("DataTables-1.10.16/images/sort_both.png")}table.dataTable thead .sorting_asc{background-image:url("DataTables-1.10.16/images/sort_asc.png")}table.dataTable thead .sorting_desc{background-image:url("DataTables-1.10.16/images/sort_desc.png")}table.dataTable thead .sorting_asc_disabled{background-image:url("DataTables-1.10.16/images/sort_asc_disabled.png")}table.dataTable thead .sorting_desc_disabled{background-image:url("DataTables-1.10.16/images/sort_desc_disabled.png")}table.dataTable tbody tr{background-color:#ffffff}table.dataTable tbody tr.selected{background-color:#B0BED9}table.dataTable tbody th,table.dataTable tbody td{padding:8px 10px}table.dataTable.row-border tbody th,table.dataTable.row-border tbody td,table.dataTable.display tbody th,table.dataTable.display tbody td{border-top:1px solid #ddd}table.dataTable.row-border tbody tr:first-child th,table.dataTable.row-border tbody tr:first-child td,table.dataTable.display tbody tr:first-child th,table.dataTable.display tbody tr:first-child td{border-top:none}table.dataTable.cell-border tbody th,table.dataTable.cell-border tbody td{border-top:1px solid #ddd;border-right:1px solid #ddd}table.dataTable.cell-border tbody tr th:first-child,table.dataTable.cell-border tbody tr td:first-child{border-left:1px solid #ddd}table.dataTable.cell-border tbody tr:first-child th,table.dataTable.cell-border tbody tr:first-child td{border-top:none}table.dataTable.stripe tbody tr.odd,table.dataTable.display tbody tr.odd{background-color:#f9f9f9}table.dataTable.stripe tbody tr.odd.selected,table.dataTable.display tbody tr.odd.selected{background-color:#acbad4}table.dataTable.hover tbody tr:hover,table.dataTable.display tbody tr:hover{background-color:#f6f6f6}table.dataTable.hover tbody tr:hover.selected,table.dataTable.display tbody tr:hover.selected{background-color:#aab7d1}table.dataTable.order-column tbody tr>.sorting_1,table.dataTable.order-column tbody tr>.sorting_2,table.dataTable.order-column tbody tr>.sorting_3,table.dataTable.display tbody tr>.sorting_1,table.dataTable.display tbody tr>.sorting_2,table.dataTable.display tbody tr>.sorting_3{background-color:#fafafa}table.dataTable.order-column tbody tr.selected>.sorting_1,table.dataTable.order-column tbody tr.selected>.sorting_2,table.dataTable.order-column tbody tr.selected>.sorting_3,table.dataTable.display tbody tr.selected>.sorting_1,table.dataTable.display tbody tr.selected>.sorting_2,table.dataTable.display tbody tr.selected>.sorting_3{background-color:#acbad5}table.dataTable.display tbody tr.odd>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd>.sorting_1{background-color:#f1f1f1}table.dataTable.display tbody tr.odd>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd>.sorting_2{background-color:#f3f3f3}table.dataTable.display tbody tr.odd>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd>.sorting_3{background-color:whitesmoke}table.dataTable.display tbody tr.odd.selected>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_1{background-color:#a6b4cd}table.dataTable.display tbody tr.odd.selected>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_2{background-color:#a8b5cf}table.dataTable.display tbody tr.odd.selected>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_3{background-color:#a9b7d1}table.dataTable.display tbody tr.even>.sorting_1,table.dataTable.order-column.stripe tbody tr.even>.sorting_1{background-color:#fafafa}table.dataTable.display tbody tr.even>.sorting_2,table.dataTable.order-column.stripe tbody tr.even>.sorting_2{background-color:#fcfcfc}table.dataTable.display tbody tr.even>.sorting_3,table.dataTable.order-column.stripe tbody tr.even>.sorting_3{background-color:#fefefe}table.dataTable.display tbody tr.even.selected>.sorting_1,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_1{background-color:#acbad5}table.dataTable.display tbody tr.even.selected>.sorting_2,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_2{background-color:#aebcd6}table.dataTable.display tbody tr.even.selected>.sorting_3,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_3{background-color:#afbdd8}table.dataTable.display tbody tr:hover>.sorting_1,table.dataTable.order-column.hover tbody tr:hover>.sorting_1{background-color:#eaeaea}table.dataTable.display tbody tr:hover>.sorting_2,table.dataTable.order-column.hover tbody tr:hover>.sorting_2{background-color:#ececec}table.dataTable.display tbody tr:hover>.sorting_3,table.dataTable.order-column.hover tbody tr:hover>.sorting_3{background-color:#efefef}table.dataTable.display tbody tr:hover.selected>.sorting_1,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_1{background-color:#a2aec7}table.dataTable.display tbody tr:hover.selected>.sorting_2,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_2{background-color:#a3b0c9}table.dataTable.display tbody tr:hover.selected>.sorting_3,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_3{background-color:#a5b2cb}table.dataTable.no-footer{border-bottom:1px solid #111}table.dataTable.nowrap th,table.dataTable.nowrap td{white-space:nowrap}table.dataTable.compact thead th,table.dataTable.compact thead td{padding:4px 17px 4px 4px}table.dataTable.compact tfoot th,table.dataTable.compact tfoot td{padding:4px}table.dataTable.compact tbody th,table.dataTable.compact tbody td{padding:4px}table.dataTable th.dt-left,table.dataTable td.dt-left{text-align:left}table.dataTable th.dt-center,table.dataTable td.dt-center,table.dataTable td.dataTables_empty{text-align:center}table.dataTable th.dt-right,table.dataTable td.dt-right{text-align:right}table.dataTable th.dt-justify,table.dataTable td.dt-justify{text-align:justify}table.dataTable th.dt-nowrap,table.dataTable td.dt-nowrap{white-space:nowrap}table.dataTable thead th.dt-head-left,table.dataTable thead td.dt-head-left,table.dataTable tfoot th.dt-head-left,table.dataTable tfoot td.dt-head-left{text-align:left}table.dataTable thead th.dt-head-center,table.dataTable thead td.dt-head-center,table.dataTable tfoot th.dt-head-center,table.dataTable tfoot td.dt-head-center{text-align:center}table.dataTable thead th.dt-head-right,table.dataTable thead td.dt-head-right,table.dataTable tfoot th.dt-head-right,table.dataTable tfoot td.dt-head-right{text-align:right}table.dataTable thead th.dt-head-justify,table.dataTable thead td.dt-head-justify,table.dataTable tfoot th.dt-head-justify,table.dataTable tfoot td.dt-head-justify{text-align:justify}table.dataTable thead th.dt-head-nowrap,table.dataTable thead td.dt-head-nowrap,table.dataTable tfoot th.dt-head-nowrap,table.dataTable tfoot td.dt-head-nowrap{white-space:nowrap}table.dataTable tbody th.dt-body-left,table.dataTable tbody td.dt-body-left{text-align:left}table.dataTable tbody th.dt-body-center,table.dataTable tbody td.dt-body-center{text-align:center}table.dataTable tbody th.dt-body-right,table.dataTable tbody td.dt-body-right{text-align:right}table.dataTable tbody th.dt-body-justify,table.dataTable tbody td.dt-body-justify{text-align:justify}table.dataTable tbody th.dt-body-nowrap,table.dataTable tbody td.dt-body-nowrap{white-space:nowrap}table.dataTable,table.dataTable th,table.dataTable td{box-sizing:content-box}.dataTables_wrapper{position:relative;clear:both;*zoom:1;zoom:1}.dataTables_wrapper .dataTables_length{float:left}.dataTables_wrapper .dataTables_filter{float:right;text-align:right}.dataTables_wrapper .dataTables_filter input{margin-left:0.5em}.dataTables_wrapper .dataTables_info{clear:both;float:left;padding-top:0.755em}.dataTables_wrapper .dataTables_paginate{float:right;text-align:right;padding-top:0.25em}.dataTables_wrapper .dataTables_paginate .paginate_button{box-sizing:border-box;display:inline-block;min-width:1.5em;padding:0.5em 1em;margin-left:2px;text-align:center;text-decoration:none !important;cursor:pointer;*cursor:hand;color:#333 !important;border:1px solid transparent;border-radius:2px}.dataTables_wrapper .dataTables_paginate .paginate_button.current,.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover{color:#333 !important;border:1px solid #979797;background-color:white;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #fff), color-stop(100%, #dcdcdc));background:-webkit-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-moz-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-ms-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-o-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:linear-gradient(to bottom, #fff 0%, #dcdcdc 100%)}.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active{cursor:default;color:#666 !important;border:1px solid transparent;background:transparent;box-shadow:none}.dataTables_wrapper .dataTables_paginate .paginate_button:hover{color:white !important;border:1px solid #111;background-color:#585858;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #585858), color-stop(100%, #111));background:-webkit-linear-gradient(top, #585858 0%, #111 100%);background:-moz-linear-gradient(top, #585858 0%, #111 100%);background:-ms-linear-gradient(top, #585858 0%, #111 100%);background:-o-linear-gradient(top, #585858 0%, #111 100%);background:linear-gradient(to bottom, #585858 0%, #111 100%)}.dataTables_wrapper .dataTables_paginate .paginate_button:active{outline:none;background-color:#2b2b2b;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #2b2b2b), color-stop(100%, #0c0c0c));background:-webkit-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-moz-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-ms-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-o-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:linear-gradient(to bottom, #2b2b2b 0%, #0c0c0c 100%);box-shadow:inset 0 0 3px #111}.dataTables_wrapper .dataTables_paginate .ellipsis{padding:0 1em}.dataTables_wrapper .dataTables_processing{position:absolute;top:50%;left:50%;width:100%;height:40px;margin-left:-50%;margin-top:-25px;padding-top:20px;text-align:center;font-size:1.2em;background-color:white;background:-webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255,255,255,0)), color-stop(25%, rgba(255,255,255,0.9)), color-stop(75%, rgba(255,255,255,0.9)), color-stop(100%, rgba(255,255,255,0)));background:-webkit-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-moz-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-ms-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-o-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%)}.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_processing,.dataTables_wrapper .dataTables_paginate{color:#333}.dataTables_wrapper .dataTables_scroll{clear:both}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody{*margin-top:-1px;-webkit-overflow-scrolling:touch}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>thead>tr>th,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>thead>tr>td,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>tbody>tr>th,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>tbody>tr>td{vertical-align:middle}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>thead>tr>th>div.dataTables_sizing,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>thead>tr>td>div.dataTables_sizing,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>tbody>tr>th>div.dataTables_sizing,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody>table>tbody>tr>td>div.dataTables_sizing{height:0;overflow:hidden;margin:0 !important;padding:0 !important}.dataTables_wrapper.no-footer .dataTables_scrollBody{border-bottom:1px solid #111}.dataTables_wrapper.no-footer div.dataTables_scrollHead table.dataTable,.dataTables_wrapper.no-footer div.dataTables_scrollBody>table{border-bottom:none}.dataTables_wrapper:after{visibility:hidden;display:block;content:"";clear:both;height:0}@media screen and (max-width: 767px){.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_paginate{float:none;text-align:center}.dataTables_wrapper .dataTables_paginate{margin-top:0.5em}}@media screen and (max-width: 640px){.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_filter{float:none;text-align:center}.dataTables_wrapper .dataTables_filter{margin-top:0.5em}}
|
14 |
+
|
15 |
+
|
16 |
+
div.dt-autofill-handle {
|
17 |
+
position: absolute;
|
18 |
+
height: 8px;
|
19 |
+
width: 8px;
|
20 |
+
z-index: 102;
|
21 |
+
box-sizing: border-box;
|
22 |
+
border: 1px solid #316ad1;
|
23 |
+
background: linear-gradient(to bottom, #abcffb 0%, #4989de 100%);
|
24 |
+
}
|
25 |
+
|
26 |
+
div.dt-autofill-select {
|
27 |
+
position: absolute;
|
28 |
+
z-index: 1001;
|
29 |
+
background-color: #4989de;
|
30 |
+
background-image: repeating-linear-gradient(45deg, transparent, transparent 5px, rgba(255, 255, 255, 0.5) 5px, rgba(255, 255, 255, 0.5) 10px);
|
31 |
+
}
|
32 |
+
div.dt-autofill-select.top, div.dt-autofill-select.bottom {
|
33 |
+
height: 3px;
|
34 |
+
margin-top: -1px;
|
35 |
+
}
|
36 |
+
div.dt-autofill-select.left, div.dt-autofill-select.right {
|
37 |
+
width: 3px;
|
38 |
+
margin-left: -1px;
|
39 |
+
}
|
40 |
+
|
41 |
+
div.dt-autofill-list {
|
42 |
+
position: fixed;
|
43 |
+
top: 50%;
|
44 |
+
left: 50%;
|
45 |
+
width: 500px;
|
46 |
+
margin-left: -250px;
|
47 |
+
background-color: white;
|
48 |
+
border-radius: 6px;
|
49 |
+
box-shadow: 0 0 5px #555;
|
50 |
+
border: 2px solid #444;
|
51 |
+
z-index: 11;
|
52 |
+
box-sizing: border-box;
|
53 |
+
padding: 1.5em 2em;
|
54 |
+
}
|
55 |
+
div.dt-autofill-list ul {
|
56 |
+
display: table;
|
57 |
+
margin: 0;
|
58 |
+
padding: 0;
|
59 |
+
list-style: none;
|
60 |
+
width: 100%;
|
61 |
+
}
|
62 |
+
div.dt-autofill-list ul li {
|
63 |
+
display: table-row;
|
64 |
+
}
|
65 |
+
div.dt-autofill-list ul li:last-child div.dt-autofill-question, div.dt-autofill-list ul li:last-child div.dt-autofill-button {
|
66 |
+
border-bottom: none;
|
67 |
+
}
|
68 |
+
div.dt-autofill-list ul li:hover {
|
69 |
+
background-color: #f6f6f6;
|
70 |
+
}
|
71 |
+
div.dt-autofill-list div.dt-autofill-question {
|
72 |
+
display: table-cell;
|
73 |
+
padding: 0.5em 0;
|
74 |
+
border-bottom: 1px solid #ccc;
|
75 |
+
}
|
76 |
+
div.dt-autofill-list div.dt-autofill-question input[type=number] {
|
77 |
+
padding: 6px;
|
78 |
+
width: 30px;
|
79 |
+
margin: -2px 0;
|
80 |
+
}
|
81 |
+
div.dt-autofill-list div.dt-autofill-button {
|
82 |
+
display: table-cell;
|
83 |
+
padding: 0.5em 0;
|
84 |
+
border-bottom: 1px solid #ccc;
|
85 |
+
}
|
86 |
+
div.dt-autofill-list div.dt-autofill-button button {
|
87 |
+
color: white;
|
88 |
+
margin: 0;
|
89 |
+
padding: 6px 12px;
|
90 |
+
text-align: center;
|
91 |
+
border: 1px solid #2e6da4;
|
92 |
+
background-color: #337ab7;
|
93 |
+
border-radius: 4px;
|
94 |
+
cursor: pointer;
|
95 |
+
vertical-align: middle;
|
96 |
+
}
|
97 |
+
|
98 |
+
div.dt-autofill-background {
|
99 |
+
position: fixed;
|
100 |
+
top: 0;
|
101 |
+
left: 0;
|
102 |
+
width: 100%;
|
103 |
+
height: 100%;
|
104 |
+
background: rgba(0, 0, 0, 0.7);
|
105 |
+
background: radial-gradient(ellipse farthest-corner at center, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.7) 100%);
|
106 |
+
z-index: 10;
|
107 |
+
}
|
108 |
+
|
109 |
+
|
110 |
+
@keyframes dtb-spinner{100%{transform:rotate(360deg)}}@-o-keyframes dtb-spinner{100%{-o-transform:rotate(360deg);transform:rotate(360deg)}}@-ms-keyframes dtb-spinner{100%{-ms-transform:rotate(360deg);transform:rotate(360deg)}}@-webkit-keyframes dtb-spinner{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes dtb-spinner{100%{-moz-transform:rotate(360deg);transform:rotate(360deg)}}div.dt-button-info{position:fixed;top:50%;left:50%;width:400px;margin-top:-100px;margin-left:-200px;background-color:white;border:2px solid #111;box-shadow:3px 3px 8px rgba(0,0,0,0.3);border-radius:3px;text-align:center;z-index:21}div.dt-button-info h2{padding:0.5em;margin:0;font-weight:normal;border-bottom:1px solid #ddd;background-color:#f3f3f3}div.dt-button-info>div{padding:1em}button.dt-button,div.dt-button,a.dt-button{position:relative;display:inline-block;box-sizing:border-box;margin-right:0.333em;margin-bottom:0.333em;padding:0.5em 1em;border:1px solid #999;border-radius:2px;cursor:pointer;font-size:0.88em;line-height:1.6em;color:black;white-space:nowrap;overflow:hidden;background-color:#e9e9e9;background-image:-webkit-linear-gradient(top, #fff 0%, #e9e9e9 100%);background-image:-moz-linear-gradient(top, #fff 0%, #e9e9e9 100%);background-image:-ms-linear-gradient(top, #fff 0%, #e9e9e9 100%);background-image:-o-linear-gradient(top, #fff 0%, #e9e9e9 100%);background-image:linear-gradient(to bottom, #fff 0%, #e9e9e9 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='white', EndColorStr='#e9e9e9');-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;text-decoration:none;outline:none}button.dt-button.disabled,div.dt-button.disabled,a.dt-button.disabled{color:#999;border:1px solid #d0d0d0;cursor:default;background-color:#f9f9f9;background-image:-webkit-linear-gradient(top, #fff 0%, #f9f9f9 100%);background-image:-moz-linear-gradient(top, #fff 0%, #f9f9f9 100%);background-image:-ms-linear-gradient(top, #fff 0%, #f9f9f9 100%);background-image:-o-linear-gradient(top, #fff 0%, #f9f9f9 100%);background-image:linear-gradient(to bottom, #fff 0%, #f9f9f9 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#ffffff', EndColorStr='#f9f9f9')}button.dt-button:active:not(.disabled),button.dt-button.active:not(.disabled),div.dt-button:active:not(.disabled),div.dt-button.active:not(.disabled),a.dt-button:active:not(.disabled),a.dt-button.active:not(.disabled){background-color:#e2e2e2;background-image:-webkit-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);background-image:-moz-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);background-image:-ms-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);background-image:-o-linear-gradient(top, #f3f3f3 0%, #e2e2e2 100%);background-image:linear-gradient(to bottom, #f3f3f3 0%, #e2e2e2 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f3f3f3', EndColorStr='#e2e2e2');box-shadow:inset 1px 1px 3px #999999}button.dt-button:active:not(.disabled):hover:not(.disabled),button.dt-button.active:not(.disabled):hover:not(.disabled),div.dt-button:active:not(.disabled):hover:not(.disabled),div.dt-button.active:not(.disabled):hover:not(.disabled),a.dt-button:active:not(.disabled):hover:not(.disabled),a.dt-button.active:not(.disabled):hover:not(.disabled){box-shadow:inset 1px 1px 3px #999999;background-color:#cccccc;background-image:-webkit-linear-gradient(top, #eaeaea 0%, #ccc 100%);background-image:-moz-linear-gradient(top, #eaeaea 0%, #ccc 100%);background-image:-ms-linear-gradient(top, #eaeaea 0%, #ccc 100%);background-image:-o-linear-gradient(top, #eaeaea 0%, #ccc 100%);background-image:linear-gradient(to bottom, #eaeaea 0%, #ccc 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#eaeaea', EndColorStr='#cccccc')}button.dt-button:hover,div.dt-button:hover,a.dt-button:hover{text-decoration:none}button.dt-button:hover:not(.disabled),div.dt-button:hover:not(.disabled),a.dt-button:hover:not(.disabled){border:1px solid #666;background-color:#e0e0e0;background-image:-webkit-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);background-image:-moz-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);background-image:-ms-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);background-image:-o-linear-gradient(top, #f9f9f9 0%, #e0e0e0 100%);background-image:linear-gradient(to bottom, #f9f9f9 0%, #e0e0e0 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f9f9f9', EndColorStr='#e0e0e0')}button.dt-button:focus:not(.disabled),div.dt-button:focus:not(.disabled),a.dt-button:focus:not(.disabled){border:1px solid #426c9e;text-shadow:0 1px 0 #c4def1;outline:none;background-color:#79ace9;background-image:-webkit-linear-gradient(top, #bddef4 0%, #79ace9 100%);background-image:-moz-linear-gradient(top, #bddef4 0%, #79ace9 100%);background-image:-ms-linear-gradient(top, #bddef4 0%, #79ace9 100%);background-image:-o-linear-gradient(top, #bddef4 0%, #79ace9 100%);background-image:linear-gradient(to bottom, #bddef4 0%, #79ace9 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#bddef4', EndColorStr='#79ace9')}.dt-button embed{outline:none}div.dt-buttons{position:relative;float:left}div.dt-buttons.buttons-right{float:right}div.dt-button-collection{position:absolute;top:0;left:0;width:150px;margin-top:3px;padding:8px 8px 4px 8px;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.4);background-color:white;overflow:hidden;z-index:2002;border-radius:5px;box-shadow:3px 3px 5px rgba(0,0,0,0.3);z-index:2002;-webkit-column-gap:8px;-moz-column-gap:8px;-ms-column-gap:8px;-o-column-gap:8px;column-gap:8px}div.dt-button-collection button.dt-button,div.dt-button-collection div.dt-button,div.dt-button-collection a.dt-button{position:relative;left:0;right:0;width:100%;display:block;float:none;margin-bottom:4px;margin-right:0}div.dt-button-collection button.dt-button:active:not(.disabled),div.dt-button-collection button.dt-button.active:not(.disabled),div.dt-button-collection div.dt-button:active:not(.disabled),div.dt-button-collection div.dt-button.active:not(.disabled),div.dt-button-collection a.dt-button:active:not(.disabled),div.dt-button-collection a.dt-button.active:not(.disabled){background-color:#dadada;background-image:-webkit-linear-gradient(top, #f0f0f0 0%, #dadada 100%);background-image:-moz-linear-gradient(top, #f0f0f0 0%, #dadada 100%);background-image:-ms-linear-gradient(top, #f0f0f0 0%, #dadada 100%);background-image:-o-linear-gradient(top, #f0f0f0 0%, #dadada 100%);background-image:linear-gradient(to bottom, #f0f0f0 0%, #dadada 100%);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#f0f0f0', EndColorStr='#dadada');box-shadow:inset 1px 1px 3px #666}div.dt-button-collection.fixed{position:fixed;top:50%;left:50%;margin-left:-75px;border-radius:0}div.dt-button-collection.fixed.two-column{margin-left:-150px}div.dt-button-collection.fixed.three-column{margin-left:-225px}div.dt-button-collection.fixed.four-column{margin-left:-300px}div.dt-button-collection>*{-webkit-column-break-inside:avoid;break-inside:avoid}div.dt-button-collection.two-column{width:300px;padding-bottom:1px;-webkit-column-count:2;-moz-column-count:2;-ms-column-count:2;-o-column-count:2;column-count:2}div.dt-button-collection.three-column{width:450px;padding-bottom:1px;-webkit-column-count:3;-moz-column-count:3;-ms-column-count:3;-o-column-count:3;column-count:3}div.dt-button-collection.four-column{width:600px;padding-bottom:1px;-webkit-column-count:4;-moz-column-count:4;-ms-column-count:4;-o-column-count:4;column-count:4}div.dt-button-collection .dt-button{border-radius:0}div.dt-button-background{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,0.7);background:-ms-radial-gradient(center, ellipse farthest-corner, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);background:-moz-radial-gradient(center, ellipse farthest-corner, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);background:-o-radial-gradient(center, ellipse farthest-corner, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);background:-webkit-gradient(radial, center center, 0, center center, 497, color-stop(0, rgba(0,0,0,0.3)), color-stop(1, rgba(0,0,0,0.7)));background:-webkit-radial-gradient(center, ellipse farthest-corner, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);background:radial-gradient(ellipse farthest-corner at center, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.7) 100%);z-index:2001}@media screen and (max-width: 640px){div.dt-buttons{float:none !important;text-align:center}}button.dt-button.processing,div.dt-button.processing,a.dt-button.processing{color:rgba(0,0,0,0.2)}button.dt-button.processing:after,div.dt-button.processing:after,a.dt-button.processing:after{position:absolute;top:50%;left:50%;width:16px;height:16px;margin:-8px 0 0 -8px;box-sizing:border-box;display:block;content:' ';border:2px solid #282828;border-radius:50%;border-left-color:transparent;border-right-color:transparent;animation:dtb-spinner 1500ms infinite linear;-o-animation:dtb-spinner 1500ms infinite linear;-ms-animation:dtb-spinner 1500ms infinite linear;-webkit-animation:dtb-spinner 1500ms infinite linear;-moz-animation:dtb-spinner 1500ms infinite linear}
|
111 |
+
|
112 |
+
|
113 |
+
table.DTCR_clonedTable.dataTable{position:absolute !important;background-color:rgba(255,255,255,0.7);z-index:202}div.DTCR_pointer{width:1px;background-color:#0259C4;z-index:201}
|
114 |
+
|
115 |
+
|
116 |
+
table.DTFC_Cloned thead,table.DTFC_Cloned tfoot{background-color:white}div.DTFC_Blocker{background-color:white}div.DTFC_LeftWrapper table.dataTable,div.DTFC_RightWrapper table.dataTable{margin-bottom:0;z-index:2}div.DTFC_LeftWrapper table.dataTable.no-footer,div.DTFC_RightWrapper table.dataTable.no-footer{border-bottom:none}
|
117 |
+
|
118 |
+
|
119 |
+
table.fixedHeader-floating{position:fixed !important;background-color:white}table.fixedHeader-floating.no-footer{border-bottom-width:0}table.fixedHeader-locked{position:absolute !important;background-color:white}@media print{table.fixedHeader-floating{display:none}}
|
120 |
+
|
121 |
+
|
122 |
+
table.dataTable th.focus,table.dataTable td.focus{outline:3px solid #3366FF;outline-offset:-1px}
|
123 |
+
|
124 |
+
|
125 |
+
table.dataTable.dtr-inline.collapsed>tbody>tr>td.child,table.dataTable.dtr-inline.collapsed>tbody>tr>th.child,table.dataTable.dtr-inline.collapsed>tbody>tr>td.dataTables_empty{cursor:default !important}table.dataTable.dtr-inline.collapsed>tbody>tr>td.child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>th.child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>td.dataTables_empty:before{display:none !important}table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>td:first-child,table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>th:first-child{position:relative;padding-left:30px;cursor:pointer}table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr[role="row"]>th:first-child:before{top:9px;left:4px;height:14px;width:14px;display:block;position:absolute;color:white;border:2px solid white;border-radius:14px;box-shadow:0 0 3px #444;box-sizing:content-box;text-align:center;text-indent:0 !important;font-family:'Courier New', Courier, monospace;line-height:14px;content:'+';background-color:#31b131}table.dataTable.dtr-inline.collapsed>tbody>tr.parent>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr.parent>th:first-child:before{content:'-';background-color:#d33333}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child{padding-left:27px}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child:before,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child:before{top:5px;left:4px;height:14px;width:14px;border-radius:14px;line-height:14px;text-indent:3px}table.dataTable.dtr-column>tbody>tr>td.control,table.dataTable.dtr-column>tbody>tr>th.control{position:relative;cursor:pointer}table.dataTable.dtr-column>tbody>tr>td.control:before,table.dataTable.dtr-column>tbody>tr>th.control:before{top:50%;left:50%;height:16px;width:16px;margin-top:-10px;margin-left:-10px;display:block;position:absolute;color:white;border:2px solid white;border-radius:14px;box-shadow:0 0 3px #444;box-sizing:content-box;text-align:center;text-indent:0 !important;font-family:'Courier New', Courier, monospace;line-height:14px;content:'+';background-color:#31b131}table.dataTable.dtr-column>tbody>tr.parent td.control:before,table.dataTable.dtr-column>tbody>tr.parent th.control:before{content:'-';background-color:#d33333}table.dataTable>tbody>tr.child{padding:0.5em 1em}table.dataTable>tbody>tr.child:hover{background:transparent !important}table.dataTable>tbody>tr.child ul.dtr-details{display:inline-block;list-style-type:none;margin:0;padding:0}table.dataTable>tbody>tr.child ul.dtr-details>li{border-bottom:1px solid #efefef;padding:0.5em 0}table.dataTable>tbody>tr.child ul.dtr-details>li:first-child{padding-top:0}table.dataTable>tbody>tr.child ul.dtr-details>li:last-child{border-bottom:none}table.dataTable>tbody>tr.child span.dtr-title{display:inline-block;min-width:75px;font-weight:bold}div.dtr-modal{position:fixed;box-sizing:border-box;top:0;left:0;height:100%;width:100%;z-index:100;padding:10em 1em}div.dtr-modal div.dtr-modal-display{position:absolute;top:0;left:0;bottom:0;right:0;width:50%;height:50%;overflow:auto;margin:auto;z-index:102;overflow:auto;background-color:#f5f5f7;border:1px solid black;border-radius:0.5em;box-shadow:0 12px 30px rgba(0,0,0,0.6)}div.dtr-modal div.dtr-modal-content{position:relative;padding:1em}div.dtr-modal div.dtr-modal-close{position:absolute;top:6px;right:6px;width:22px;height:22px;border:1px solid #eaeaea;background-color:#f9f9f9;text-align:center;border-radius:3px;cursor:pointer;z-index:12}div.dtr-modal div.dtr-modal-close:hover{background-color:#eaeaea}div.dtr-modal div.dtr-modal-background{position:fixed;top:0;left:0;right:0;bottom:0;z-index:101;background:rgba(0,0,0,0.6)}@media screen and (max-width: 767px){div.dtr-modal div.dtr-modal-display{width:95%}}
|
126 |
+
|
127 |
+
|
128 |
+
table.dt-rowReorder-float{position:absolute !important;opacity:0.8;table-layout:fixed;outline:2px solid #888;outline-offset:-2px;z-index:2001}tr.dt-rowReorder-moving{outline:2px solid #555;outline-offset:-2px}body.dt-rowReorder-noOverflow{overflow-x:hidden}table.dataTable td.reorder{text-align:center;cursor:move}
|
129 |
+
|
130 |
+
|
131 |
+
div.DTS{display:block !important}div.DTS tbody th,div.DTS tbody td{white-space:nowrap}div.DTS div.DTS_Loading{z-index:1}div.DTS div.dataTables_scrollBody{background:repeating-linear-gradient(45deg, #edeeff, #edeeff 10px, #fff 10px, #fff 20px)}div.DTS div.dataTables_scrollBody table{z-index:2}div.DTS div.dataTables_paginate,div.DTS div.dataTables_length{display:none}
|
132 |
+
|
133 |
+
|
134 |
+
table.dataTable tbody>tr.selected,table.dataTable tbody>tr>.selected{background-color:#B0BED9}table.dataTable.stripe tbody>tr.odd.selected,table.dataTable.stripe tbody>tr.odd>.selected,table.dataTable.display tbody>tr.odd.selected,table.dataTable.display tbody>tr.odd>.selected{background-color:#acbad4}table.dataTable.hover tbody>tr.selected:hover,table.dataTable.hover tbody>tr>.selected:hover,table.dataTable.display tbody>tr.selected:hover,table.dataTable.display tbody>tr>.selected:hover{background-color:#aab7d1}table.dataTable.order-column tbody>tr.selected>.sorting_1,table.dataTable.order-column tbody>tr.selected>.sorting_2,table.dataTable.order-column tbody>tr.selected>.sorting_3,table.dataTable.order-column tbody>tr>.selected,table.dataTable.display tbody>tr.selected>.sorting_1,table.dataTable.display tbody>tr.selected>.sorting_2,table.dataTable.display tbody>tr.selected>.sorting_3,table.dataTable.display tbody>tr>.selected{background-color:#acbad5}table.dataTable.display tbody>tr.odd.selected>.sorting_1,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_1{background-color:#a6b4cd}table.dataTable.display tbody>tr.odd.selected>.sorting_2,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_2{background-color:#a8b5cf}table.dataTable.display tbody>tr.odd.selected>.sorting_3,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_3{background-color:#a9b7d1}table.dataTable.display tbody>tr.even.selected>.sorting_1,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_1{background-color:#acbad5}table.dataTable.display tbody>tr.even.selected>.sorting_2,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_2{background-color:#aebcd6}table.dataTable.display tbody>tr.even.selected>.sorting_3,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_3{background-color:#afbdd8}table.dataTable.display tbody>tr.odd>.selected,table.dataTable.order-column.stripe tbody>tr.odd>.selected{background-color:#a6b4cd}table.dataTable.display tbody>tr.even>.selected,table.dataTable.order-column.stripe tbody>tr.even>.selected{background-color:#acbad5}table.dataTable.display tbody>tr.selected:hover>.sorting_1,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_1{background-color:#a2aec7}table.dataTable.display tbody>tr.selected:hover>.sorting_2,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_2{background-color:#a3b0c9}table.dataTable.display tbody>tr.selected:hover>.sorting_3,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_3{background-color:#a5b2cb}table.dataTable.display tbody>tr:hover>.selected,table.dataTable.display tbody>tr>.selected:hover,table.dataTable.order-column.hover tbody>tr:hover>.selected,table.dataTable.order-column.hover tbody>tr>.selected:hover{background-color:#a2aec7}table.dataTable tbody td.select-checkbox,table.dataTable tbody th.select-checkbox{position:relative}table.dataTable tbody td.select-checkbox:before,table.dataTable tbody td.select-checkbox:after,table.dataTable tbody th.select-checkbox:before,table.dataTable tbody th.select-checkbox:after{display:block;position:absolute;top:1.2em;left:50%;width:12px;height:12px;box-sizing:border-box}table.dataTable tbody td.select-checkbox:before,table.dataTable tbody th.select-checkbox:before{content:' ';margin-top:-6px;margin-left:-6px;border:1px solid black;border-radius:3px}table.dataTable tr.selected td.select-checkbox:after,table.dataTable tr.selected th.select-checkbox:after{content:'\2714';margin-top:-11px;margin-left:-4px;text-align:center;text-shadow:1px 1px #B0BED9, -1px -1px #B0BED9, 1px -1px #B0BED9, -1px 1px #B0BED9}div.dataTables_wrapper span.select-info,div.dataTables_wrapper span.select-item{margin-left:0.5em}@media screen and (max-width: 640px){div.dataTables_wrapper span.select-info,div.dataTables_wrapper span.select-item{margin-left:0;display:block}}
|
135 |
+
|
136 |
+
|
common/vendor/datatables/datatables.min.js
ADDED
@@ -0,0 +1,466 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* This combined file was created by the DataTables downloader builder:
|
3 |
+
* https://datatables.net/download
|
4 |
+
*
|
5 |
+
* To rebuild or modify this file with the latest versions of the included
|
6 |
+
* software please visit:
|
7 |
+
* https://datatables.net/download/#dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5
|
8 |
+
*
|
9 |
+
* Included libraries:
|
10 |
+
* DataTables 1.10.16, AutoFill 2.2.2, Buttons 1.5.1, ColReorder 1.4.1, FixedColumns 3.2.4, FixedHeader 3.1.3, KeyTable 2.3.2, Responsive 2.2.1, RowReorder 1.2.3, Scroller 1.4.4, Select 1.2.5
|
11 |
+
*/
|
12 |
+
|
13 |
+
/*!
|
14 |
+
DataTables 1.10.16
|
15 |
+
©2008-2017 SpryMedia Ltd - datatables.net/license
|
16 |
+
*/
|
17 |
+
(function(h){"function"===typeof define&&define.amd?define(["jquery"],function(E){return h(E,window,document)}):"object"===typeof exports?module.exports=function(E,G){E||(E=window);G||(G="undefined"!==typeof window?require("jquery"):require("jquery")(E));return h(G,E,E.document)}:h(jQuery,window,document)})(function(h,E,G,k){function X(a){var b,c,d={};h.each(a,function(e){if((b=e.match(/^([^A-Z]+?)([A-Z])/))&&-1!=="a aa ai ao as b fn i m o s ".indexOf(b[1]+" "))c=e.replace(b[0],b[2].toLowerCase()),
|
18 |
+
d[c]=e,"o"===b[1]&&X(a[e])});a._hungarianMap=d}function I(a,b,c){a._hungarianMap||X(a);var d;h.each(b,function(e){d=a._hungarianMap[e];if(d!==k&&(c||b[d]===k))"o"===d.charAt(0)?(b[d]||(b[d]={}),h.extend(!0,b[d],b[e]),I(a[d],b[d],c)):b[d]=b[e]})}function Ca(a){var b=m.defaults.oLanguage,c=a.sZeroRecords;!a.sEmptyTable&&(c&&"No data available in table"===b.sEmptyTable)&&F(a,a,"sZeroRecords","sEmptyTable");!a.sLoadingRecords&&(c&&"Loading..."===b.sLoadingRecords)&&F(a,a,"sZeroRecords","sLoadingRecords");
|
19 |
+
a.sInfoThousands&&(a.sThousands=a.sInfoThousands);(a=a.sDecimal)&&cb(a)}function db(a){A(a,"ordering","bSort");A(a,"orderMulti","bSortMulti");A(a,"orderClasses","bSortClasses");A(a,"orderCellsTop","bSortCellsTop");A(a,"order","aaSorting");A(a,"orderFixed","aaSortingFixed");A(a,"paging","bPaginate");A(a,"pagingType","sPaginationType");A(a,"pageLength","iDisplayLength");A(a,"searching","bFilter");"boolean"===typeof a.sScrollX&&(a.sScrollX=a.sScrollX?"100%":"");"boolean"===typeof a.scrollX&&(a.scrollX=
|
20 |
+
a.scrollX?"100%":"");if(a=a.aoSearchCols)for(var b=0,c=a.length;b<c;b++)a[b]&&I(m.models.oSearch,a[b])}function eb(a){A(a,"orderable","bSortable");A(a,"orderData","aDataSort");A(a,"orderSequence","asSorting");A(a,"orderDataType","sortDataType");var b=a.aDataSort;"number"===typeof b&&!h.isArray(b)&&(a.aDataSort=[b])}function fb(a){if(!m.__browser){var b={};m.__browser=b;var c=h("<div/>").css({position:"fixed",top:0,left:-1*h(E).scrollLeft(),height:1,width:1,overflow:"hidden"}).append(h("<div/>").css({position:"absolute",
|
21 |
+
top:1,left:1,width:100,overflow:"scroll"}).append(h("<div/>").css({width:"100%",height:10}))).appendTo("body"),d=c.children(),e=d.children();b.barWidth=d[0].offsetWidth-d[0].clientWidth;b.bScrollOversize=100===e[0].offsetWidth&&100!==d[0].clientWidth;b.bScrollbarLeft=1!==Math.round(e.offset().left);b.bBounding=c[0].getBoundingClientRect().width?!0:!1;c.remove()}h.extend(a.oBrowser,m.__browser);a.oScroll.iBarWidth=m.__browser.barWidth}function gb(a,b,c,d,e,f){var g,j=!1;c!==k&&(g=c,j=!0);for(;d!==
|
22 |
+
e;)a.hasOwnProperty(d)&&(g=j?b(g,a[d],d,a):a[d],j=!0,d+=f);return g}function Da(a,b){var c=m.defaults.column,d=a.aoColumns.length,c=h.extend({},m.models.oColumn,c,{nTh:b?b:G.createElement("th"),sTitle:c.sTitle?c.sTitle:b?b.innerHTML:"",aDataSort:c.aDataSort?c.aDataSort:[d],mData:c.mData?c.mData:d,idx:d});a.aoColumns.push(c);c=a.aoPreSearchCols;c[d]=h.extend({},m.models.oSearch,c[d]);ja(a,d,h(b).data())}function ja(a,b,c){var b=a.aoColumns[b],d=a.oClasses,e=h(b.nTh);if(!b.sWidthOrig){b.sWidthOrig=
|
23 |
+
e.attr("width")||null;var f=(e.attr("style")||"").match(/width:\s*(\d+[pxem%]+)/);f&&(b.sWidthOrig=f[1])}c!==k&&null!==c&&(eb(c),I(m.defaults.column,c),c.mDataProp!==k&&!c.mData&&(c.mData=c.mDataProp),c.sType&&(b._sManualType=c.sType),c.className&&!c.sClass&&(c.sClass=c.className),c.sClass&&e.addClass(c.sClass),h.extend(b,c),F(b,c,"sWidth","sWidthOrig"),c.iDataSort!==k&&(b.aDataSort=[c.iDataSort]),F(b,c,"aDataSort"));var g=b.mData,j=Q(g),i=b.mRender?Q(b.mRender):null,c=function(a){return"string"===
|
24 |
+
typeof a&&-1!==a.indexOf("@")};b._bAttrSrc=h.isPlainObject(g)&&(c(g.sort)||c(g.type)||c(g.filter));b._setter=null;b.fnGetData=function(a,b,c){var d=j(a,b,k,c);return i&&b?i(d,b,a,c):d};b.fnSetData=function(a,b,c){return R(g)(a,b,c)};"number"!==typeof g&&(a._rowReadObject=!0);a.oFeatures.bSort||(b.bSortable=!1,e.addClass(d.sSortableNone));a=-1!==h.inArray("asc",b.asSorting);c=-1!==h.inArray("desc",b.asSorting);!b.bSortable||!a&&!c?(b.sSortingClass=d.sSortableNone,b.sSortingClassJUI=""):a&&!c?(b.sSortingClass=
|
25 |
+
d.sSortableAsc,b.sSortingClassJUI=d.sSortJUIAscAllowed):!a&&c?(b.sSortingClass=d.sSortableDesc,b.sSortingClassJUI=d.sSortJUIDescAllowed):(b.sSortingClass=d.sSortable,b.sSortingClassJUI=d.sSortJUI)}function Y(a){if(!1!==a.oFeatures.bAutoWidth){var b=a.aoColumns;Ea(a);for(var c=0,d=b.length;c<d;c++)b[c].nTh.style.width=b[c].sWidth}b=a.oScroll;(""!==b.sY||""!==b.sX)&&ka(a);r(a,null,"column-sizing",[a])}function Z(a,b){var c=la(a,"bVisible");return"number"===typeof c[b]?c[b]:null}function $(a,b){var c=
|
26 |
+
la(a,"bVisible"),c=h.inArray(b,c);return-1!==c?c:null}function aa(a){var b=0;h.each(a.aoColumns,function(a,d){d.bVisible&&"none"!==h(d.nTh).css("display")&&b++});return b}function la(a,b){var c=[];h.map(a.aoColumns,function(a,e){a[b]&&c.push(e)});return c}function Fa(a){var b=a.aoColumns,c=a.aoData,d=m.ext.type.detect,e,f,g,j,i,h,l,q,t;e=0;for(f=b.length;e<f;e++)if(l=b[e],t=[],!l.sType&&l._sManualType)l.sType=l._sManualType;else if(!l.sType){g=0;for(j=d.length;g<j;g++){i=0;for(h=c.length;i<h;i++){t[i]===
|
27 |
+
k&&(t[i]=B(a,i,e,"type"));q=d[g](t[i],a);if(!q&&g!==d.length-1)break;if("html"===q)break}if(q){l.sType=q;break}}l.sType||(l.sType="string")}}function hb(a,b,c,d){var e,f,g,j,i,n,l=a.aoColumns;if(b)for(e=b.length-1;0<=e;e--){n=b[e];var q=n.targets!==k?n.targets:n.aTargets;h.isArray(q)||(q=[q]);f=0;for(g=q.length;f<g;f++)if("number"===typeof q[f]&&0<=q[f]){for(;l.length<=q[f];)Da(a);d(q[f],n)}else if("number"===typeof q[f]&&0>q[f])d(l.length+q[f],n);else if("string"===typeof q[f]){j=0;for(i=l.length;j<
|
28 |
+
i;j++)("_all"==q[f]||h(l[j].nTh).hasClass(q[f]))&&d(j,n)}}if(c){e=0;for(a=c.length;e<a;e++)d(e,c[e])}}function M(a,b,c,d){var e=a.aoData.length,f=h.extend(!0,{},m.models.oRow,{src:c?"dom":"data",idx:e});f._aData=b;a.aoData.push(f);for(var g=a.aoColumns,j=0,i=g.length;j<i;j++)g[j].sType=null;a.aiDisplayMaster.push(e);b=a.rowIdFn(b);b!==k&&(a.aIds[b]=f);(c||!a.oFeatures.bDeferRender)&&Ga(a,e,c,d);return e}function ma(a,b){var c;b instanceof h||(b=h(b));return b.map(function(b,e){c=Ha(a,e);return M(a,
|
29 |
+
c.data,e,c.cells)})}function B(a,b,c,d){var e=a.iDraw,f=a.aoColumns[c],g=a.aoData[b]._aData,j=f.sDefaultContent,i=f.fnGetData(g,d,{settings:a,row:b,col:c});if(i===k)return a.iDrawError!=e&&null===j&&(J(a,0,"Requested unknown parameter "+("function"==typeof f.mData?"{function}":"'"+f.mData+"'")+" for row "+b+", column "+c,4),a.iDrawError=e),j;if((i===g||null===i)&&null!==j&&d!==k)i=j;else if("function"===typeof i)return i.call(g);return null===i&&"display"==d?"":i}function ib(a,b,c,d){a.aoColumns[c].fnSetData(a.aoData[b]._aData,
|
30 |
+
d,{settings:a,row:b,col:c})}function Ia(a){return h.map(a.match(/(\\.|[^\.])+/g)||[""],function(a){return a.replace(/\\\./g,".")})}function Q(a){if(h.isPlainObject(a)){var b={};h.each(a,function(a,c){c&&(b[a]=Q(c))});return function(a,c,f,g){var j=b[c]||b._;return j!==k?j(a,c,f,g):a}}if(null===a)return function(a){return a};if("function"===typeof a)return function(b,c,f,g){return a(b,c,f,g)};if("string"===typeof a&&(-1!==a.indexOf(".")||-1!==a.indexOf("[")||-1!==a.indexOf("("))){var c=function(a,
|
31 |
+
b,f){var g,j;if(""!==f){j=Ia(f);for(var i=0,n=j.length;i<n;i++){f=j[i].match(ba);g=j[i].match(U);if(f){j[i]=j[i].replace(ba,"");""!==j[i]&&(a=a[j[i]]);g=[];j.splice(0,i+1);j=j.join(".");if(h.isArray(a)){i=0;for(n=a.length;i<n;i++)g.push(c(a[i],b,j))}a=f[0].substring(1,f[0].length-1);a=""===a?g:g.join(a);break}else if(g){j[i]=j[i].replace(U,"");a=a[j[i]]();continue}if(null===a||a[j[i]]===k)return k;a=a[j[i]]}}return a};return function(b,e){return c(b,e,a)}}return function(b){return b[a]}}function R(a){if(h.isPlainObject(a))return R(a._);
|
32 |
+
if(null===a)return function(){};if("function"===typeof a)return function(b,d,e){a(b,"set",d,e)};if("string"===typeof a&&(-1!==a.indexOf(".")||-1!==a.indexOf("[")||-1!==a.indexOf("("))){var b=function(a,d,e){var e=Ia(e),f;f=e[e.length-1];for(var g,j,i=0,n=e.length-1;i<n;i++){g=e[i].match(ba);j=e[i].match(U);if(g){e[i]=e[i].replace(ba,"");a[e[i]]=[];f=e.slice();f.splice(0,i+1);g=f.join(".");if(h.isArray(d)){j=0;for(n=d.length;j<n;j++)f={},b(f,d[j],g),a[e[i]].push(f)}else a[e[i]]=d;return}j&&(e[i]=e[i].replace(U,
|
33 |
+
""),a=a[e[i]](d));if(null===a[e[i]]||a[e[i]]===k)a[e[i]]={};a=a[e[i]]}if(f.match(U))a[f.replace(U,"")](d);else a[f.replace(ba,"")]=d};return function(c,d){return b(c,d,a)}}return function(b,d){b[a]=d}}function Ja(a){return D(a.aoData,"_aData")}function na(a){a.aoData.length=0;a.aiDisplayMaster.length=0;a.aiDisplay.length=0;a.aIds={}}function oa(a,b,c){for(var d=-1,e=0,f=a.length;e<f;e++)a[e]==b?d=e:a[e]>b&&a[e]--; -1!=d&&c===k&&a.splice(d,1)}function ca(a,b,c,d){var e=a.aoData[b],f,g=function(c,d){for(;c.childNodes.length;)c.removeChild(c.firstChild);
|
34 |
+
c.innerHTML=B(a,b,d,"display")};if("dom"===c||(!c||"auto"===c)&&"dom"===e.src)e._aData=Ha(a,e,d,d===k?k:e._aData).data;else{var j=e.anCells;if(j)if(d!==k)g(j[d],d);else{c=0;for(f=j.length;c<f;c++)g(j[c],c)}}e._aSortData=null;e._aFilterData=null;g=a.aoColumns;if(d!==k)g[d].sType=null;else{c=0;for(f=g.length;c<f;c++)g[c].sType=null;Ka(a,e)}}function Ha(a,b,c,d){var e=[],f=b.firstChild,g,j,i=0,n,l=a.aoColumns,q=a._rowReadObject,d=d!==k?d:q?{}:[],t=function(a,b){if("string"===typeof a){var c=a.indexOf("@");
|
35 |
+
-1!==c&&(c=a.substring(c+1),R(a)(d,b.getAttribute(c)))}},m=function(a){if(c===k||c===i)j=l[i],n=h.trim(a.innerHTML),j&&j._bAttrSrc?(R(j.mData._)(d,n),t(j.mData.sort,a),t(j.mData.type,a),t(j.mData.filter,a)):q?(j._setter||(j._setter=R(j.mData)),j._setter(d,n)):d[i]=n;i++};if(f)for(;f;){g=f.nodeName.toUpperCase();if("TD"==g||"TH"==g)m(f),e.push(f);f=f.nextSibling}else{e=b.anCells;f=0;for(g=e.length;f<g;f++)m(e[f])}if(b=b.firstChild?b:b.nTr)(b=b.getAttribute("id"))&&R(a.rowId)(d,b);return{data:d,cells:e}}
|
36 |
+
function Ga(a,b,c,d){var e=a.aoData[b],f=e._aData,g=[],j,i,n,l,q;if(null===e.nTr){j=c||G.createElement("tr");e.nTr=j;e.anCells=g;j._DT_RowIndex=b;Ka(a,e);l=0;for(q=a.aoColumns.length;l<q;l++){n=a.aoColumns[l];i=c?d[l]:G.createElement(n.sCellType);i._DT_CellIndex={row:b,column:l};g.push(i);if((!c||n.mRender||n.mData!==l)&&(!h.isPlainObject(n.mData)||n.mData._!==l+".display"))i.innerHTML=B(a,b,l,"display");n.sClass&&(i.className+=" "+n.sClass);n.bVisible&&!c?j.appendChild(i):!n.bVisible&&c&&i.parentNode.removeChild(i);
|
37 |
+
n.fnCreatedCell&&n.fnCreatedCell.call(a.oInstance,i,B(a,b,l),f,b,l)}r(a,"aoRowCreatedCallback",null,[j,f,b])}e.nTr.setAttribute("role","row")}function Ka(a,b){var c=b.nTr,d=b._aData;if(c){var e=a.rowIdFn(d);e&&(c.id=e);d.DT_RowClass&&(e=d.DT_RowClass.split(" "),b.__rowc=b.__rowc?qa(b.__rowc.concat(e)):e,h(c).removeClass(b.__rowc.join(" ")).addClass(d.DT_RowClass));d.DT_RowAttr&&h(c).attr(d.DT_RowAttr);d.DT_RowData&&h(c).data(d.DT_RowData)}}function jb(a){var b,c,d,e,f,g=a.nTHead,j=a.nTFoot,i=0===
|
38 |
+
h("th, td",g).length,n=a.oClasses,l=a.aoColumns;i&&(e=h("<tr/>").appendTo(g));b=0;for(c=l.length;b<c;b++)f=l[b],d=h(f.nTh).addClass(f.sClass),i&&d.appendTo(e),a.oFeatures.bSort&&(d.addClass(f.sSortingClass),!1!==f.bSortable&&(d.attr("tabindex",a.iTabIndex).attr("aria-controls",a.sTableId),La(a,f.nTh,b))),f.sTitle!=d[0].innerHTML&&d.html(f.sTitle),Ma(a,"header")(a,d,f,n);i&&da(a.aoHeader,g);h(g).find(">tr").attr("role","row");h(g).find(">tr>th, >tr>td").addClass(n.sHeaderTH);h(j).find(">tr>th, >tr>td").addClass(n.sFooterTH);
|
39 |
+
if(null!==j){a=a.aoFooter[0];b=0;for(c=a.length;b<c;b++)f=l[b],f.nTf=a[b].cell,f.sClass&&h(f.nTf).addClass(f.sClass)}}function ea(a,b,c){var d,e,f,g=[],j=[],i=a.aoColumns.length,n;if(b){c===k&&(c=!1);d=0;for(e=b.length;d<e;d++){g[d]=b[d].slice();g[d].nTr=b[d].nTr;for(f=i-1;0<=f;f--)!a.aoColumns[f].bVisible&&!c&&g[d].splice(f,1);j.push([])}d=0;for(e=g.length;d<e;d++){if(a=g[d].nTr)for(;f=a.firstChild;)a.removeChild(f);f=0;for(b=g[d].length;f<b;f++)if(n=i=1,j[d][f]===k){a.appendChild(g[d][f].cell);
|
40 |
+
for(j[d][f]=1;g[d+i]!==k&&g[d][f].cell==g[d+i][f].cell;)j[d+i][f]=1,i++;for(;g[d][f+n]!==k&&g[d][f].cell==g[d][f+n].cell;){for(c=0;c<i;c++)j[d+c][f+n]=1;n++}h(g[d][f].cell).attr("rowspan",i).attr("colspan",n)}}}}function N(a){var b=r(a,"aoPreDrawCallback","preDraw",[a]);if(-1!==h.inArray(!1,b))C(a,!1);else{var b=[],c=0,d=a.asStripeClasses,e=d.length,f=a.oLanguage,g=a.iInitDisplayStart,j="ssp"==y(a),i=a.aiDisplay;a.bDrawing=!0;g!==k&&-1!==g&&(a._iDisplayStart=j?g:g>=a.fnRecordsDisplay()?0:g,a.iInitDisplayStart=
|
41 |
+
-1);var g=a._iDisplayStart,n=a.fnDisplayEnd();if(a.bDeferLoading)a.bDeferLoading=!1,a.iDraw++,C(a,!1);else if(j){if(!a.bDestroying&&!kb(a))return}else a.iDraw++;if(0!==i.length){f=j?a.aoData.length:n;for(j=j?0:g;j<f;j++){var l=i[j],q=a.aoData[l];null===q.nTr&&Ga(a,l);l=q.nTr;if(0!==e){var t=d[c%e];q._sRowStripe!=t&&(h(l).removeClass(q._sRowStripe).addClass(t),q._sRowStripe=t)}r(a,"aoRowCallback",null,[l,q._aData,c,j]);b.push(l);c++}}else c=f.sZeroRecords,1==a.iDraw&&"ajax"==y(a)?c=f.sLoadingRecords:
|
42 |
+
f.sEmptyTable&&0===a.fnRecordsTotal()&&(c=f.sEmptyTable),b[0]=h("<tr/>",{"class":e?d[0]:""}).append(h("<td />",{valign:"top",colSpan:aa(a),"class":a.oClasses.sRowEmpty}).html(c))[0];r(a,"aoHeaderCallback","header",[h(a.nTHead).children("tr")[0],Ja(a),g,n,i]);r(a,"aoFooterCallback","footer",[h(a.nTFoot).children("tr")[0],Ja(a),g,n,i]);d=h(a.nTBody);d.children().detach();d.append(h(b));r(a,"aoDrawCallback","draw",[a]);a.bSorted=!1;a.bFiltered=!1;a.bDrawing=!1}}function S(a,b){var c=a.oFeatures,d=c.bFilter;
|
43 |
+
c.bSort&&lb(a);d?fa(a,a.oPreviousSearch):a.aiDisplay=a.aiDisplayMaster.slice();!0!==b&&(a._iDisplayStart=0);a._drawHold=b;N(a);a._drawHold=!1}function mb(a){var b=a.oClasses,c=h(a.nTable),c=h("<div/>").insertBefore(c),d=a.oFeatures,e=h("<div/>",{id:a.sTableId+"_wrapper","class":b.sWrapper+(a.nTFoot?"":" "+b.sNoFooter)});a.nHolding=c[0];a.nTableWrapper=e[0];a.nTableReinsertBefore=a.nTable.nextSibling;for(var f=a.sDom.split(""),g,j,i,n,l,q,k=0;k<f.length;k++){g=null;j=f[k];if("<"==j){i=h("<div/>")[0];
|
44 |
+
n=f[k+1];if("'"==n||'"'==n){l="";for(q=2;f[k+q]!=n;)l+=f[k+q],q++;"H"==l?l=b.sJUIHeader:"F"==l&&(l=b.sJUIFooter);-1!=l.indexOf(".")?(n=l.split("."),i.id=n[0].substr(1,n[0].length-1),i.className=n[1]):"#"==l.charAt(0)?i.id=l.substr(1,l.length-1):i.className=l;k+=q}e.append(i);e=h(i)}else if(">"==j)e=e.parent();else if("l"==j&&d.bPaginate&&d.bLengthChange)g=nb(a);else if("f"==j&&d.bFilter)g=ob(a);else if("r"==j&&d.bProcessing)g=pb(a);else if("t"==j)g=qb(a);else if("i"==j&&d.bInfo)g=rb(a);else if("p"==
|
45 |
+
j&&d.bPaginate)g=sb(a);else if(0!==m.ext.feature.length){i=m.ext.feature;q=0;for(n=i.length;q<n;q++)if(j==i[q].cFeature){g=i[q].fnInit(a);break}}g&&(i=a.aanFeatures,i[j]||(i[j]=[]),i[j].push(g),e.append(g))}c.replaceWith(e);a.nHolding=null}function da(a,b){var c=h(b).children("tr"),d,e,f,g,j,i,n,l,q,k;a.splice(0,a.length);f=0;for(i=c.length;f<i;f++)a.push([]);f=0;for(i=c.length;f<i;f++){d=c[f];for(e=d.firstChild;e;){if("TD"==e.nodeName.toUpperCase()||"TH"==e.nodeName.toUpperCase()){l=1*e.getAttribute("colspan");
|
46 |
+
q=1*e.getAttribute("rowspan");l=!l||0===l||1===l?1:l;q=!q||0===q||1===q?1:q;g=0;for(j=a[f];j[g];)g++;n=g;k=1===l?!0:!1;for(j=0;j<l;j++)for(g=0;g<q;g++)a[f+g][n+j]={cell:e,unique:k},a[f+g].nTr=d}e=e.nextSibling}}}function ra(a,b,c){var d=[];c||(c=a.aoHeader,b&&(c=[],da(c,b)));for(var b=0,e=c.length;b<e;b++)for(var f=0,g=c[b].length;f<g;f++)if(c[b][f].unique&&(!d[f]||!a.bSortCellsTop))d[f]=c[b][f].cell;return d}function sa(a,b,c){r(a,"aoServerParams","serverParams",[b]);if(b&&h.isArray(b)){var d={},
|
47 |
+
e=/(.*?)\[\]$/;h.each(b,function(a,b){var c=b.name.match(e);c?(c=c[0],d[c]||(d[c]=[]),d[c].push(b.value)):d[b.name]=b.value});b=d}var f,g=a.ajax,j=a.oInstance,i=function(b){r(a,null,"xhr",[a,b,a.jqXHR]);c(b)};if(h.isPlainObject(g)&&g.data){f=g.data;var n=h.isFunction(f)?f(b,a):f,b=h.isFunction(f)&&n?n:h.extend(!0,b,n);delete g.data}n={data:b,success:function(b){var c=b.error||b.sError;c&&J(a,0,c);a.json=b;i(b)},dataType:"json",cache:!1,type:a.sServerMethod,error:function(b,c){var d=r(a,null,"xhr",
|
48 |
+
[a,null,a.jqXHR]);-1===h.inArray(!0,d)&&("parsererror"==c?J(a,0,"Invalid JSON response",1):4===b.readyState&&J(a,0,"Ajax error",7));C(a,!1)}};a.oAjaxData=b;r(a,null,"preXhr",[a,b]);a.fnServerData?a.fnServerData.call(j,a.sAjaxSource,h.map(b,function(a,b){return{name:b,value:a}}),i,a):a.sAjaxSource||"string"===typeof g?a.jqXHR=h.ajax(h.extend(n,{url:g||a.sAjaxSource})):h.isFunction(g)?a.jqXHR=g.call(j,b,i,a):(a.jqXHR=h.ajax(h.extend(n,g)),g.data=f)}function kb(a){return a.bAjaxDataGet?(a.iDraw++,C(a,
|
49 |
+
!0),sa(a,tb(a),function(b){ub(a,b)}),!1):!0}function tb(a){var b=a.aoColumns,c=b.length,d=a.oFeatures,e=a.oPreviousSearch,f=a.aoPreSearchCols,g,j=[],i,n,l,k=V(a);g=a._iDisplayStart;i=!1!==d.bPaginate?a._iDisplayLength:-1;var t=function(a,b){j.push({name:a,value:b})};t("sEcho",a.iDraw);t("iColumns",c);t("sColumns",D(b,"sName").join(","));t("iDisplayStart",g);t("iDisplayLength",i);var pa={draw:a.iDraw,columns:[],order:[],start:g,length:i,search:{value:e.sSearch,regex:e.bRegex}};for(g=0;g<c;g++)n=b[g],
|
50 |
+
l=f[g],i="function"==typeof n.mData?"function":n.mData,pa.columns.push({data:i,name:n.sName,searchable:n.bSearchable,orderable:n.bSortable,search:{value:l.sSearch,regex:l.bRegex}}),t("mDataProp_"+g,i),d.bFilter&&(t("sSearch_"+g,l.sSearch),t("bRegex_"+g,l.bRegex),t("bSearchable_"+g,n.bSearchable)),d.bSort&&t("bSortable_"+g,n.bSortable);d.bFilter&&(t("sSearch",e.sSearch),t("bRegex",e.bRegex));d.bSort&&(h.each(k,function(a,b){pa.order.push({column:b.col,dir:b.dir});t("iSortCol_"+a,b.col);t("sSortDir_"+
|
51 |
+
a,b.dir)}),t("iSortingCols",k.length));b=m.ext.legacy.ajax;return null===b?a.sAjaxSource?j:pa:b?j:pa}function ub(a,b){var c=ta(a,b),d=b.sEcho!==k?b.sEcho:b.draw,e=b.iTotalRecords!==k?b.iTotalRecords:b.recordsTotal,f=b.iTotalDisplayRecords!==k?b.iTotalDisplayRecords:b.recordsFiltered;if(d){if(1*d<a.iDraw)return;a.iDraw=1*d}na(a);a._iRecordsTotal=parseInt(e,10);a._iRecordsDisplay=parseInt(f,10);d=0;for(e=c.length;d<e;d++)M(a,c[d]);a.aiDisplay=a.aiDisplayMaster.slice();a.bAjaxDataGet=!1;N(a);a._bInitComplete||
|
52 |
+
ua(a,b);a.bAjaxDataGet=!0;C(a,!1)}function ta(a,b){var c=h.isPlainObject(a.ajax)&&a.ajax.dataSrc!==k?a.ajax.dataSrc:a.sAjaxDataProp;return"data"===c?b.aaData||b[c]:""!==c?Q(c)(b):b}function ob(a){var b=a.oClasses,c=a.sTableId,d=a.oLanguage,e=a.oPreviousSearch,f=a.aanFeatures,g='<input type="search" class="'+b.sFilterInput+'"/>',j=d.sSearch,j=j.match(/_INPUT_/)?j.replace("_INPUT_",g):j+g,b=h("<div/>",{id:!f.f?c+"_filter":null,"class":b.sFilter}).append(h("<label/>").append(j)),f=function(){var b=!this.value?
|
53 |
+
"":this.value;b!=e.sSearch&&(fa(a,{sSearch:b,bRegex:e.bRegex,bSmart:e.bSmart,bCaseInsensitive:e.bCaseInsensitive}),a._iDisplayStart=0,N(a))},g=null!==a.searchDelay?a.searchDelay:"ssp"===y(a)?400:0,i=h("input",b).val(e.sSearch).attr("placeholder",d.sSearchPlaceholder).on("keyup.DT search.DT input.DT paste.DT cut.DT",g?Na(f,g):f).on("keypress.DT",function(a){if(13==a.keyCode)return!1}).attr("aria-controls",c);h(a.nTable).on("search.dt.DT",function(b,c){if(a===c)try{i[0]!==G.activeElement&&i.val(e.sSearch)}catch(d){}});
|
54 |
+
return b[0]}function fa(a,b,c){var d=a.oPreviousSearch,e=a.aoPreSearchCols,f=function(a){d.sSearch=a.sSearch;d.bRegex=a.bRegex;d.bSmart=a.bSmart;d.bCaseInsensitive=a.bCaseInsensitive};Fa(a);if("ssp"!=y(a)){vb(a,b.sSearch,c,b.bEscapeRegex!==k?!b.bEscapeRegex:b.bRegex,b.bSmart,b.bCaseInsensitive);f(b);for(b=0;b<e.length;b++)wb(a,e[b].sSearch,b,e[b].bEscapeRegex!==k?!e[b].bEscapeRegex:e[b].bRegex,e[b].bSmart,e[b].bCaseInsensitive);xb(a)}else f(b);a.bFiltered=!0;r(a,null,"search",[a])}function xb(a){for(var b=
|
55 |
+
m.ext.search,c=a.aiDisplay,d,e,f=0,g=b.length;f<g;f++){for(var j=[],i=0,n=c.length;i<n;i++)e=c[i],d=a.aoData[e],b[f](a,d._aFilterData,e,d._aData,i)&&j.push(e);c.length=0;h.merge(c,j)}}function wb(a,b,c,d,e,f){if(""!==b){for(var g=[],j=a.aiDisplay,d=Oa(b,d,e,f),e=0;e<j.length;e++)b=a.aoData[j[e]]._aFilterData[c],d.test(b)&&g.push(j[e]);a.aiDisplay=g}}function vb(a,b,c,d,e,f){var d=Oa(b,d,e,f),f=a.oPreviousSearch.sSearch,g=a.aiDisplayMaster,j,e=[];0!==m.ext.search.length&&(c=!0);j=yb(a);if(0>=b.length)a.aiDisplay=
|
56 |
+
g.slice();else{if(j||c||f.length>b.length||0!==b.indexOf(f)||a.bSorted)a.aiDisplay=g.slice();b=a.aiDisplay;for(c=0;c<b.length;c++)d.test(a.aoData[b[c]]._sFilterRow)&&e.push(b[c]);a.aiDisplay=e}}function Oa(a,b,c,d){a=b?a:Pa(a);c&&(a="^(?=.*?"+h.map(a.match(/"[^"]+"|[^ ]+/g)||[""],function(a){if('"'===a.charAt(0))var b=a.match(/^"(.*)"$/),a=b?b[1]:a;return a.replace('"',"")}).join(")(?=.*?")+").*$");return RegExp(a,d?"i":"")}function yb(a){var b=a.aoColumns,c,d,e,f,g,j,i,h,l=m.ext.type.search;c=!1;
|
57 |
+
d=0;for(f=a.aoData.length;d<f;d++)if(h=a.aoData[d],!h._aFilterData){j=[];e=0;for(g=b.length;e<g;e++)c=b[e],c.bSearchable?(i=B(a,d,e,"filter"),l[c.sType]&&(i=l[c.sType](i)),null===i&&(i=""),"string"!==typeof i&&i.toString&&(i=i.toString())):i="",i.indexOf&&-1!==i.indexOf("&")&&(va.innerHTML=i,i=Wb?va.textContent:va.innerText),i.replace&&(i=i.replace(/[\r\n]/g,"")),j.push(i);h._aFilterData=j;h._sFilterRow=j.join(" ");c=!0}return c}function zb(a){return{search:a.sSearch,smart:a.bSmart,regex:a.bRegex,
|
58 |
+
caseInsensitive:a.bCaseInsensitive}}function Ab(a){return{sSearch:a.search,bSmart:a.smart,bRegex:a.regex,bCaseInsensitive:a.caseInsensitive}}function rb(a){var b=a.sTableId,c=a.aanFeatures.i,d=h("<div/>",{"class":a.oClasses.sInfo,id:!c?b+"_info":null});c||(a.aoDrawCallback.push({fn:Bb,sName:"information"}),d.attr("role","status").attr("aria-live","polite"),h(a.nTable).attr("aria-describedby",b+"_info"));return d[0]}function Bb(a){var b=a.aanFeatures.i;if(0!==b.length){var c=a.oLanguage,d=a._iDisplayStart+
|
59 |
+
1,e=a.fnDisplayEnd(),f=a.fnRecordsTotal(),g=a.fnRecordsDisplay(),j=g?c.sInfo:c.sInfoEmpty;g!==f&&(j+=" "+c.sInfoFiltered);j+=c.sInfoPostFix;j=Cb(a,j);c=c.fnInfoCallback;null!==c&&(j=c.call(a.oInstance,a,d,e,f,g,j));h(b).html(j)}}function Cb(a,b){var c=a.fnFormatNumber,d=a._iDisplayStart+1,e=a._iDisplayLength,f=a.fnRecordsDisplay(),g=-1===e;return b.replace(/_START_/g,c.call(a,d)).replace(/_END_/g,c.call(a,a.fnDisplayEnd())).replace(/_MAX_/g,c.call(a,a.fnRecordsTotal())).replace(/_TOTAL_/g,c.call(a,
|
60 |
+
f)).replace(/_PAGE_/g,c.call(a,g?1:Math.ceil(d/e))).replace(/_PAGES_/g,c.call(a,g?1:Math.ceil(f/e)))}function ga(a){var b,c,d=a.iInitDisplayStart,e=a.aoColumns,f;c=a.oFeatures;var g=a.bDeferLoading;if(a.bInitialised){mb(a);jb(a);ea(a,a.aoHeader);ea(a,a.aoFooter);C(a,!0);c.bAutoWidth&&Ea(a);b=0;for(c=e.length;b<c;b++)f=e[b],f.sWidth&&(f.nTh.style.width=v(f.sWidth));r(a,null,"preInit",[a]);S(a);e=y(a);if("ssp"!=e||g)"ajax"==e?sa(a,[],function(c){var f=ta(a,c);for(b=0;b<f.length;b++)M(a,f[b]);a.iInitDisplayStart=
|
61 |
+
d;S(a);C(a,!1);ua(a,c)},a):(C(a,!1),ua(a))}else setTimeout(function(){ga(a)},200)}function ua(a,b){a._bInitComplete=!0;(b||a.oInit.aaData)&&Y(a);r(a,null,"plugin-init",[a,b]);r(a,"aoInitComplete","init",[a,b])}function Qa(a,b){var c=parseInt(b,10);a._iDisplayLength=c;Ra(a);r(a,null,"length",[a,c])}function nb(a){for(var b=a.oClasses,c=a.sTableId,d=a.aLengthMenu,e=h.isArray(d[0]),f=e?d[0]:d,d=e?d[1]:d,e=h("<select/>",{name:c+"_length","aria-controls":c,"class":b.sLengthSelect}),g=0,j=f.length;g<j;g++)e[0][g]=
|
62 |
+
new Option("number"===typeof d[g]?a.fnFormatNumber(d[g]):d[g],f[g]);var i=h("<div><label/></div>").addClass(b.sLength);a.aanFeatures.l||(i[0].id=c+"_length");i.children().append(a.oLanguage.sLengthMenu.replace("_MENU_",e[0].outerHTML));h("select",i).val(a._iDisplayLength).on("change.DT",function(){Qa(a,h(this).val());N(a)});h(a.nTable).on("length.dt.DT",function(b,c,d){a===c&&h("select",i).val(d)});return i[0]}function sb(a){var b=a.sPaginationType,c=m.ext.pager[b],d="function"===typeof c,e=function(a){N(a)},
|
63 |
+
b=h("<div/>").addClass(a.oClasses.sPaging+b)[0],f=a.aanFeatures;d||c.fnInit(a,b,e);f.p||(b.id=a.sTableId+"_paginate",a.aoDrawCallback.push({fn:function(a){if(d){var b=a._iDisplayStart,i=a._iDisplayLength,h=a.fnRecordsDisplay(),l=-1===i,b=l?0:Math.ceil(b/i),i=l?1:Math.ceil(h/i),h=c(b,i),k,l=0;for(k=f.p.length;l<k;l++)Ma(a,"pageButton")(a,f.p[l],l,h,b,i)}else c.fnUpdate(a,e)},sName:"pagination"}));return b}function Sa(a,b,c){var d=a._iDisplayStart,e=a._iDisplayLength,f=a.fnRecordsDisplay();0===f||-1===
|
64 |
+
e?d=0:"number"===typeof b?(d=b*e,d>f&&(d=0)):"first"==b?d=0:"previous"==b?(d=0<=e?d-e:0,0>d&&(d=0)):"next"==b?d+e<f&&(d+=e):"last"==b?d=Math.floor((f-1)/e)*e:J(a,0,"Unknown paging action: "+b,5);b=a._iDisplayStart!==d;a._iDisplayStart=d;b&&(r(a,null,"page",[a]),c&&N(a));return b}function pb(a){return h("<div/>",{id:!a.aanFeatures.r?a.sTableId+"_processing":null,"class":a.oClasses.sProcessing}).html(a.oLanguage.sProcessing).insertBefore(a.nTable)[0]}function C(a,b){a.oFeatures.bProcessing&&h(a.aanFeatures.r).css("display",
|
65 |
+
b?"block":"none");r(a,null,"processing",[a,b])}function qb(a){var b=h(a.nTable);b.attr("role","grid");var c=a.oScroll;if(""===c.sX&&""===c.sY)return a.nTable;var d=c.sX,e=c.sY,f=a.oClasses,g=b.children("caption"),j=g.length?g[0]._captionSide:null,i=h(b[0].cloneNode(!1)),n=h(b[0].cloneNode(!1)),l=b.children("tfoot");l.length||(l=null);i=h("<div/>",{"class":f.sScrollWrapper}).append(h("<div/>",{"class":f.sScrollHead}).css({overflow:"hidden",position:"relative",border:0,width:d?!d?null:v(d):"100%"}).append(h("<div/>",
|
66 |
+
{"class":f.sScrollHeadInner}).css({"box-sizing":"content-box",width:c.sXInner||"100%"}).append(i.removeAttr("id").css("margin-left",0).append("top"===j?g:null).append(b.children("thead"))))).append(h("<div/>",{"class":f.sScrollBody}).css({position:"relative",overflow:"auto",width:!d?null:v(d)}).append(b));l&&i.append(h("<div/>",{"class":f.sScrollFoot}).css({overflow:"hidden",border:0,width:d?!d?null:v(d):"100%"}).append(h("<div/>",{"class":f.sScrollFootInner}).append(n.removeAttr("id").css("margin-left",
|
67 |
+
0).append("bottom"===j?g:null).append(b.children("tfoot")))));var b=i.children(),k=b[0],f=b[1],t=l?b[2]:null;if(d)h(f).on("scroll.DT",function(){var a=this.scrollLeft;k.scrollLeft=a;l&&(t.scrollLeft=a)});h(f).css(e&&c.bCollapse?"max-height":"height",e);a.nScrollHead=k;a.nScrollBody=f;a.nScrollFoot=t;a.aoDrawCallback.push({fn:ka,sName:"scrolling"});return i[0]}function ka(a){var b=a.oScroll,c=b.sX,d=b.sXInner,e=b.sY,b=b.iBarWidth,f=h(a.nScrollHead),g=f[0].style,j=f.children("div"),i=j[0].style,n=j.children("table"),
|
68 |
+
j=a.nScrollBody,l=h(j),q=j.style,t=h(a.nScrollFoot).children("div"),m=t.children("table"),o=h(a.nTHead),p=h(a.nTable),s=p[0],r=s.style,u=a.nTFoot?h(a.nTFoot):null,x=a.oBrowser,T=x.bScrollOversize,Xb=D(a.aoColumns,"nTh"),O,K,P,w,Ta=[],y=[],z=[],A=[],B,C=function(a){a=a.style;a.paddingTop="0";a.paddingBottom="0";a.borderTopWidth="0";a.borderBottomWidth="0";a.height=0};K=j.scrollHeight>j.clientHeight;if(a.scrollBarVis!==K&&a.scrollBarVis!==k)a.scrollBarVis=K,Y(a);else{a.scrollBarVis=K;p.children("thead, tfoot").remove();
|
69 |
+
u&&(P=u.clone().prependTo(p),O=u.find("tr"),P=P.find("tr"));w=o.clone().prependTo(p);o=o.find("tr");K=w.find("tr");w.find("th, td").removeAttr("tabindex");c||(q.width="100%",f[0].style.width="100%");h.each(ra(a,w),function(b,c){B=Z(a,b);c.style.width=a.aoColumns[B].sWidth});u&&H(function(a){a.style.width=""},P);f=p.outerWidth();if(""===c){r.width="100%";if(T&&(p.find("tbody").height()>j.offsetHeight||"scroll"==l.css("overflow-y")))r.width=v(p.outerWidth()-b);f=p.outerWidth()}else""!==d&&(r.width=
|
70 |
+
v(d),f=p.outerWidth());H(C,K);H(function(a){z.push(a.innerHTML);Ta.push(v(h(a).css("width")))},K);H(function(a,b){if(h.inArray(a,Xb)!==-1)a.style.width=Ta[b]},o);h(K).height(0);u&&(H(C,P),H(function(a){A.push(a.innerHTML);y.push(v(h(a).css("width")))},P),H(function(a,b){a.style.width=y[b]},O),h(P).height(0));H(function(a,b){a.innerHTML='<div class="dataTables_sizing" style="height:0;overflow:hidden;">'+z[b]+"</div>";a.style.width=Ta[b]},K);u&&H(function(a,b){a.innerHTML='<div class="dataTables_sizing" style="height:0;overflow:hidden;">'+
|
71 |
+
A[b]+"</div>";a.style.width=y[b]},P);if(p.outerWidth()<f){O=j.scrollHeight>j.offsetHeight||"scroll"==l.css("overflow-y")?f+b:f;if(T&&(j.scrollHeight>j.offsetHeight||"scroll"==l.css("overflow-y")))r.width=v(O-b);(""===c||""!==d)&&J(a,1,"Possible column misalignment",6)}else O="100%";q.width=v(O);g.width=v(O);u&&(a.nScrollFoot.style.width=v(O));!e&&T&&(q.height=v(s.offsetHeight+b));c=p.outerWidth();n[0].style.width=v(c);i.width=v(c);d=p.height()>j.clientHeight||"scroll"==l.css("overflow-y");e="padding"+
|
72 |
+
(x.bScrollbarLeft?"Left":"Right");i[e]=d?b+"px":"0px";u&&(m[0].style.width=v(c),t[0].style.width=v(c),t[0].style[e]=d?b+"px":"0px");p.children("colgroup").insertBefore(p.children("thead"));l.scroll();if((a.bSorted||a.bFiltered)&&!a._drawHold)j.scrollTop=0}}function H(a,b,c){for(var d=0,e=0,f=b.length,g,j;e<f;){g=b[e].firstChild;for(j=c?c[e].firstChild:null;g;)1===g.nodeType&&(c?a(g,j,d):a(g,d),d++),g=g.nextSibling,j=c?j.nextSibling:null;e++}}function Ea(a){var b=a.nTable,c=a.aoColumns,d=a.oScroll,
|
73 |
+
e=d.sY,f=d.sX,g=d.sXInner,j=c.length,i=la(a,"bVisible"),n=h("th",a.nTHead),l=b.getAttribute("width"),k=b.parentNode,t=!1,m,o,p=a.oBrowser,d=p.bScrollOversize;(m=b.style.width)&&-1!==m.indexOf("%")&&(l=m);for(m=0;m<i.length;m++)o=c[i[m]],null!==o.sWidth&&(o.sWidth=Db(o.sWidthOrig,k),t=!0);if(d||!t&&!f&&!e&&j==aa(a)&&j==n.length)for(m=0;m<j;m++)i=Z(a,m),null!==i&&(c[i].sWidth=v(n.eq(m).width()));else{j=h(b).clone().css("visibility","hidden").removeAttr("id");j.find("tbody tr").remove();var s=h("<tr/>").appendTo(j.find("tbody"));
|
74 |
+
j.find("thead, tfoot").remove();j.append(h(a.nTHead).clone()).append(h(a.nTFoot).clone());j.find("tfoot th, tfoot td").css("width","");n=ra(a,j.find("thead")[0]);for(m=0;m<i.length;m++)o=c[i[m]],n[m].style.width=null!==o.sWidthOrig&&""!==o.sWidthOrig?v(o.sWidthOrig):"",o.sWidthOrig&&f&&h(n[m]).append(h("<div/>").css({width:o.sWidthOrig,margin:0,padding:0,border:0,height:1}));if(a.aoData.length)for(m=0;m<i.length;m++)t=i[m],o=c[t],h(Eb(a,t)).clone(!1).append(o.sContentPadding).appendTo(s);h("[name]",
|
75 |
+
j).removeAttr("name");o=h("<div/>").css(f||e?{position:"absolute",top:0,left:0,height:1,right:0,overflow:"hidden"}:{}).append(j).appendTo(k);f&&g?j.width(g):f?(j.css("width","auto"),j.removeAttr("width"),j.width()<k.clientWidth&&l&&j.width(k.clientWidth)):e?j.width(k.clientWidth):l&&j.width(l);for(m=e=0;m<i.length;m++)k=h(n[m]),g=k.outerWidth()-k.width(),k=p.bBounding?Math.ceil(n[m].getBoundingClientRect().width):k.outerWidth(),e+=k,c[i[m]].sWidth=v(k-g);b.style.width=v(e);o.remove()}l&&(b.style.width=
|
76 |
+
v(l));if((l||f)&&!a._reszEvt)b=function(){h(E).on("resize.DT-"+a.sInstance,Na(function(){Y(a)}))},d?setTimeout(b,1E3):b(),a._reszEvt=!0}function Db(a,b){if(!a)return 0;var c=h("<div/>").css("width",v(a)).appendTo(b||G.body),d=c[0].offsetWidth;c.remove();return d}function Eb(a,b){var c=Fb(a,b);if(0>c)return null;var d=a.aoData[c];return!d.nTr?h("<td/>").html(B(a,c,b,"display"))[0]:d.anCells[b]}function Fb(a,b){for(var c,d=-1,e=-1,f=0,g=a.aoData.length;f<g;f++)c=B(a,f,b,"display")+"",c=c.replace(Yb,
|
77 |
+
""),c=c.replace(/ /g," "),c.length>d&&(d=c.length,e=f);return e}function v(a){return null===a?"0px":"number"==typeof a?0>a?"0px":a+"px":a.match(/\d$/)?a+"px":a}function V(a){var b,c,d=[],e=a.aoColumns,f,g,j,i;b=a.aaSortingFixed;c=h.isPlainObject(b);var n=[];f=function(a){a.length&&!h.isArray(a[0])?n.push(a):h.merge(n,a)};h.isArray(b)&&f(b);c&&b.pre&&f(b.pre);f(a.aaSorting);c&&b.post&&f(b.post);for(a=0;a<n.length;a++){i=n[a][0];f=e[i].aDataSort;b=0;for(c=f.length;b<c;b++)g=f[b],j=e[g].sType||
|
78 |
+
"string",n[a]._idx===k&&(n[a]._idx=h.inArray(n[a][1],e[g].asSorting)),d.push({src:i,col:g,dir:n[a][1],index:n[a]._idx,type:j,formatter:m.ext.type.order[j+"-pre"]})}return d}function lb(a){var b,c,d=[],e=m.ext.type.order,f=a.aoData,g=0,j,i=a.aiDisplayMaster,h;Fa(a);h=V(a);b=0;for(c=h.length;b<c;b++)j=h[b],j.formatter&&g++,Gb(a,j.col);if("ssp"!=y(a)&&0!==h.length){b=0;for(c=i.length;b<c;b++)d[i[b]]=b;g===h.length?i.sort(function(a,b){var c,e,g,j,i=h.length,k=f[a]._aSortData,m=f[b]._aSortData;for(g=
|
79 |
+
0;g<i;g++)if(j=h[g],c=k[j.col],e=m[j.col],c=c<e?-1:c>e?1:0,0!==c)return"asc"===j.dir?c:-c;c=d[a];e=d[b];return c<e?-1:c>e?1:0}):i.sort(function(a,b){var c,g,j,i,k=h.length,m=f[a]._aSortData,o=f[b]._aSortData;for(j=0;j<k;j++)if(i=h[j],c=m[i.col],g=o[i.col],i=e[i.type+"-"+i.dir]||e["string-"+i.dir],c=i(c,g),0!==c)return c;c=d[a];g=d[b];return c<g?-1:c>g?1:0})}a.bSorted=!0}function Hb(a){for(var b,c,d=a.aoColumns,e=V(a),a=a.oLanguage.oAria,f=0,g=d.length;f<g;f++){c=d[f];var j=c.asSorting;b=c.sTitle.replace(/<.*?>/g,
|
80 |
+
"");var i=c.nTh;i.removeAttribute("aria-sort");c.bSortable&&(0<e.length&&e[0].col==f?(i.setAttribute("aria-sort","asc"==e[0].dir?"ascending":"descending"),c=j[e[0].index+1]||j[0]):c=j[0],b+="asc"===c?a.sSortAscending:a.sSortDescending);i.setAttribute("aria-label",b)}}function Ua(a,b,c,d){var e=a.aaSorting,f=a.aoColumns[b].asSorting,g=function(a,b){var c=a._idx;c===k&&(c=h.inArray(a[1],f));return c+1<f.length?c+1:b?null:0};"number"===typeof e[0]&&(e=a.aaSorting=[e]);c&&a.oFeatures.bSortMulti?(c=h.inArray(b,
|
81 |
+
D(e,"0")),-1!==c?(b=g(e[c],!0),null===b&&1===e.length&&(b=0),null===b?e.splice(c,1):(e[c][1]=f[b],e[c]._idx=b)):(e.push([b,f[0],0]),e[e.length-1]._idx=0)):e.length&&e[0][0]==b?(b=g(e[0]),e.length=1,e[0][1]=f[b],e[0]._idx=b):(e.length=0,e.push([b,f[0]]),e[0]._idx=0);S(a);"function"==typeof d&&d(a)}function La(a,b,c,d){var e=a.aoColumns[c];Va(b,{},function(b){!1!==e.bSortable&&(a.oFeatures.bProcessing?(C(a,!0),setTimeout(function(){Ua(a,c,b.shiftKey,d);"ssp"!==y(a)&&C(a,!1)},0)):Ua(a,c,b.shiftKey,d))})}
|
82 |
+
function wa(a){var b=a.aLastSort,c=a.oClasses.sSortColumn,d=V(a),e=a.oFeatures,f,g;if(e.bSort&&e.bSortClasses){e=0;for(f=b.length;e<f;e++)g=b[e].src,h(D(a.aoData,"anCells",g)).removeClass(c+(2>e?e+1:3));e=0;for(f=d.length;e<f;e++)g=d[e].src,h(D(a.aoData,"anCells",g)).addClass(c+(2>e?e+1:3))}a.aLastSort=d}function Gb(a,b){var c=a.aoColumns[b],d=m.ext.order[c.sSortDataType],e;d&&(e=d.call(a.oInstance,a,b,$(a,b)));for(var f,g=m.ext.type.order[c.sType+"-pre"],j=0,i=a.aoData.length;j<i;j++)if(c=a.aoData[j],
|
83 |
+
c._aSortData||(c._aSortData=[]),!c._aSortData[b]||d)f=d?e[j]:B(a,j,b,"sort"),c._aSortData[b]=g?g(f):f}function xa(a){if(a.oFeatures.bStateSave&&!a.bDestroying){var b={time:+new Date,start:a._iDisplayStart,length:a._iDisplayLength,order:h.extend(!0,[],a.aaSorting),search:zb(a.oPreviousSearch),columns:h.map(a.aoColumns,function(b,d){return{visible:b.bVisible,search:zb(a.aoPreSearchCols[d])}})};r(a,"aoStateSaveParams","stateSaveParams",[a,b]);a.oSavedState=b;a.fnStateSaveCallback.call(a.oInstance,a,
|
84 |
+
b)}}function Ib(a,b,c){var d,e,f=a.aoColumns,b=function(b){if(b&&b.time){var g=r(a,"aoStateLoadParams","stateLoadParams",[a,b]);if(-1===h.inArray(!1,g)&&(g=a.iStateDuration,!(0<g&&b.time<+new Date-1E3*g)&&!(b.columns&&f.length!==b.columns.length))){a.oLoadedState=h.extend(!0,{},b);b.start!==k&&(a._iDisplayStart=b.start,a.iInitDisplayStart=b.start);b.length!==k&&(a._iDisplayLength=b.length);b.order!==k&&(a.aaSorting=[],h.each(b.order,function(b,c){a.aaSorting.push(c[0]>=f.length?[0,c[1]]:c)}));b.search!==
|
85 |
+
k&&h.extend(a.oPreviousSearch,Ab(b.search));if(b.columns){d=0;for(e=b.columns.length;d<e;d++)g=b.columns[d],g.visible!==k&&(f[d].bVisible=g.visible),g.search!==k&&h.extend(a.aoPreSearchCols[d],Ab(g.search))}r(a,"aoStateLoaded","stateLoaded",[a,b])}}c()};if(a.oFeatures.bStateSave){var g=a.fnStateLoadCallback.call(a.oInstance,a,b);g!==k&&b(g)}else c()}function ya(a){var b=m.settings,a=h.inArray(a,D(b,"nTable"));return-1!==a?b[a]:null}function J(a,b,c,d){c="DataTables warning: "+(a?"table id="+a.sTableId+
|
86 |
+
" - ":"")+c;d&&(c+=". For more information about this error, please see http://datatables.net/tn/"+d);if(b)E.console&&console.log&&console.log(c);else if(b=m.ext,b=b.sErrMode||b.errMode,a&&r(a,null,"error",[a,d,c]),"alert"==b)alert(c);else{if("throw"==b)throw Error(c);"function"==typeof b&&b(a,d,c)}}function F(a,b,c,d){h.isArray(c)?h.each(c,function(c,d){h.isArray(d)?F(a,b,d[0],d[1]):F(a,b,d)}):(d===k&&(d=c),b[c]!==k&&(a[d]=b[c]))}function Jb(a,b,c){var d,e;for(e in b)b.hasOwnProperty(e)&&(d=b[e],
|
87 |
+
h.isPlainObject(d)?(h.isPlainObject(a[e])||(a[e]={}),h.extend(!0,a[e],d)):a[e]=c&&"data"!==e&&"aaData"!==e&&h.isArray(d)?d.slice():d);return a}function Va(a,b,c){h(a).on("click.DT",b,function(b){a.blur();c(b)}).on("keypress.DT",b,function(a){13===a.which&&(a.preventDefault(),c(a))}).on("selectstart.DT",function(){return!1})}function z(a,b,c,d){c&&a[b].push({fn:c,sName:d})}function r(a,b,c,d){var e=[];b&&(e=h.map(a[b].slice().reverse(),function(b){return b.fn.apply(a.oInstance,d)}));null!==c&&(b=h.Event(c+
|
88 |
+
".dt"),h(a.nTable).trigger(b,d),e.push(b.result));return e}function Ra(a){var b=a._iDisplayStart,c=a.fnDisplayEnd(),d=a._iDisplayLength;b>=c&&(b=c-d);b-=b%d;if(-1===d||0>b)b=0;a._iDisplayStart=b}function Ma(a,b){var c=a.renderer,d=m.ext.renderer[b];return h.isPlainObject(c)&&c[b]?d[c[b]]||d._:"string"===typeof c?d[c]||d._:d._}function y(a){return a.oFeatures.bServerSide?"ssp":a.ajax||a.sAjaxSource?"ajax":"dom"}function ha(a,b){var c=[],c=Kb.numbers_length,d=Math.floor(c/2);b<=c?c=W(0,b):a<=d?(c=W(0,
|
89 |
+
c-2),c.push("ellipsis"),c.push(b-1)):(a>=b-1-d?c=W(b-(c-2),b):(c=W(a-d+2,a+d-1),c.push("ellipsis"),c.push(b-1)),c.splice(0,0,"ellipsis"),c.splice(0,0,0));c.DT_el="span";return c}function cb(a){h.each({num:function(b){return za(b,a)},"num-fmt":function(b){return za(b,a,Wa)},"html-num":function(b){return za(b,a,Aa)},"html-num-fmt":function(b){return za(b,a,Aa,Wa)}},function(b,c){x.type.order[b+a+"-pre"]=c;b.match(/^html\-/)&&(x.type.search[b+a]=x.type.search.html)})}function Lb(a){return function(){var b=
|
90 |
+
[ya(this[m.ext.iApiIndex])].concat(Array.prototype.slice.call(arguments));return m.ext.internal[a].apply(this,b)}}var m=function(a){this.$=function(a,b){return this.api(!0).$(a,b)};this._=function(a,b){return this.api(!0).rows(a,b).data()};this.api=function(a){return a?new s(ya(this[x.iApiIndex])):new s(this)};this.fnAddData=function(a,b){var c=this.api(!0),d=h.isArray(a)&&(h.isArray(a[0])||h.isPlainObject(a[0]))?c.rows.add(a):c.row.add(a);(b===k||b)&&c.draw();return d.flatten().toArray()};this.fnAdjustColumnSizing=
|
91 |
+
function(a){var b=this.api(!0).columns.adjust(),c=b.settings()[0],d=c.oScroll;a===k||a?b.draw(!1):(""!==d.sX||""!==d.sY)&&ka(c)};this.fnClearTable=function(a){var b=this.api(!0).clear();(a===k||a)&&b.draw()};this.fnClose=function(a){this.api(!0).row(a).child.hide()};this.fnDeleteRow=function(a,b,c){var d=this.api(!0),a=d.rows(a),e=a.settings()[0],h=e.aoData[a[0][0]];a.remove();b&&b.call(this,e,h);(c===k||c)&&d.draw();return h};this.fnDestroy=function(a){this.api(!0).destroy(a)};this.fnDraw=function(a){this.api(!0).draw(a)};
|
92 |
+
this.fnFilter=function(a,b,c,d,e,h){e=this.api(!0);null===b||b===k?e.search(a,c,d,h):e.column(b).search(a,c,d,h);e.draw()};this.fnGetData=function(a,b){var c=this.api(!0);if(a!==k){var d=a.nodeName?a.nodeName.toLowerCase():"";return b!==k||"td"==d||"th"==d?c.cell(a,b).data():c.row(a).data()||null}return c.data().toArray()};this.fnGetNodes=function(a){var b=this.api(!0);return a!==k?b.row(a).node():b.rows().nodes().flatten().toArray()};this.fnGetPosition=function(a){var b=this.api(!0),c=a.nodeName.toUpperCase();
|
93 |
+
return"TR"==c?b.row(a).index():"TD"==c||"TH"==c?(a=b.cell(a).index(),[a.row,a.columnVisible,a.column]):null};this.fnIsOpen=function(a){return this.api(!0).row(a).child.isShown()};this.fnOpen=function(a,b,c){return this.api(!0).row(a).child(b,c).show().child()[0]};this.fnPageChange=function(a,b){var c=this.api(!0).page(a);(b===k||b)&&c.draw(!1)};this.fnSetColumnVis=function(a,b,c){a=this.api(!0).column(a).visible(b);(c===k||c)&&a.columns.adjust().draw()};this.fnSettings=function(){return ya(this[x.iApiIndex])};
|
94 |
+
this.fnSort=function(a){this.api(!0).order(a).draw()};this.fnSortListener=function(a,b,c){this.api(!0).order.listener(a,b,c)};this.fnUpdate=function(a,b,c,d,e){var h=this.api(!0);c===k||null===c?h.row(b).data(a):h.cell(b,c).data(a);(e===k||e)&&h.columns.adjust();(d===k||d)&&h.draw();return 0};this.fnVersionCheck=x.fnVersionCheck;var b=this,c=a===k,d=this.length;c&&(a={});this.oApi=this.internal=x.internal;for(var e in m.ext.internal)e&&(this[e]=Lb(e));this.each(function(){var e={},g=1<d?Jb(e,a,!0):
|
95 |
+
a,j=0,i,e=this.getAttribute("id"),n=!1,l=m.defaults,q=h(this);if("table"!=this.nodeName.toLowerCase())J(null,0,"Non-table node initialisation ("+this.nodeName+")",2);else{db(l);eb(l.column);I(l,l,!0);I(l.column,l.column,!0);I(l,h.extend(g,q.data()));var t=m.settings,j=0;for(i=t.length;j<i;j++){var o=t[j];if(o.nTable==this||o.nTHead.parentNode==this||o.nTFoot&&o.nTFoot.parentNode==this){var s=g.bRetrieve!==k?g.bRetrieve:l.bRetrieve;if(c||s)return o.oInstance;if(g.bDestroy!==k?g.bDestroy:l.bDestroy){o.oInstance.fnDestroy();
|
96 |
+
break}else{J(o,0,"Cannot reinitialise DataTable",3);return}}if(o.sTableId==this.id){t.splice(j,1);break}}if(null===e||""===e)this.id=e="DataTables_Table_"+m.ext._unique++;var p=h.extend(!0,{},m.models.oSettings,{sDestroyWidth:q[0].style.width,sInstance:e,sTableId:e});p.nTable=this;p.oApi=b.internal;p.oInit=g;t.push(p);p.oInstance=1===b.length?b:q.dataTable();db(g);g.oLanguage&&Ca(g.oLanguage);g.aLengthMenu&&!g.iDisplayLength&&(g.iDisplayLength=h.isArray(g.aLengthMenu[0])?g.aLengthMenu[0][0]:g.aLengthMenu[0]);
|
97 |
+
g=Jb(h.extend(!0,{},l),g);F(p.oFeatures,g,"bPaginate bLengthChange bFilter bSort bSortMulti bInfo bProcessing bAutoWidth bSortClasses bServerSide bDeferRender".split(" "));F(p,g,["asStripeClasses","ajax","fnServerData","fnFormatNumber","sServerMethod","aaSorting","aaSortingFixed","aLengthMenu","sPaginationType","sAjaxSource","sAjaxDataProp","iStateDuration","sDom","bSortCellsTop","iTabIndex","fnStateLoadCallback","fnStateSaveCallback","renderer","searchDelay","rowId",["iCookieDuration","iStateDuration"],
|
98 |
+
["oSearch","oPreviousSearch"],["aoSearchCols","aoPreSearchCols"],["iDisplayLength","_iDisplayLength"]]);F(p.oScroll,g,[["sScrollX","sX"],["sScrollXInner","sXInner"],["sScrollY","sY"],["bScrollCollapse","bCollapse"]]);F(p.oLanguage,g,"fnInfoCallback");z(p,"aoDrawCallback",g.fnDrawCallback,"user");z(p,"aoServerParams",g.fnServerParams,"user");z(p,"aoStateSaveParams",g.fnStateSaveParams,"user");z(p,"aoStateLoadParams",g.fnStateLoadParams,"user");z(p,"aoStateLoaded",g.fnStateLoaded,"user");z(p,"aoRowCallback",
|
99 |
+
g.fnRowCallback,"user");z(p,"aoRowCreatedCallback",g.fnCreatedRow,"user");z(p,"aoHeaderCallback",g.fnHeaderCallback,"user");z(p,"aoFooterCallback",g.fnFooterCallback,"user");z(p,"aoInitComplete",g.fnInitComplete,"user");z(p,"aoPreDrawCallback",g.fnPreDrawCallback,"user");p.rowIdFn=Q(g.rowId);fb(p);var u=p.oClasses;h.extend(u,m.ext.classes,g.oClasses);q.addClass(u.sTable);p.iInitDisplayStart===k&&(p.iInitDisplayStart=g.iDisplayStart,p._iDisplayStart=g.iDisplayStart);null!==g.iDeferLoading&&(p.bDeferLoading=
|
100 |
+
!0,e=h.isArray(g.iDeferLoading),p._iRecordsDisplay=e?g.iDeferLoading[0]:g.iDeferLoading,p._iRecordsTotal=e?g.iDeferLoading[1]:g.iDeferLoading);var v=p.oLanguage;h.extend(!0,v,g.oLanguage);v.sUrl&&(h.ajax({dataType:"json",url:v.sUrl,success:function(a){Ca(a);I(l.oLanguage,a);h.extend(true,v,a);ga(p)},error:function(){ga(p)}}),n=!0);null===g.asStripeClasses&&(p.asStripeClasses=[u.sStripeOdd,u.sStripeEven]);var e=p.asStripeClasses,x=q.children("tbody").find("tr").eq(0);-1!==h.inArray(!0,h.map(e,function(a){return x.hasClass(a)}))&&
|
101 |
+
(h("tbody tr",this).removeClass(e.join(" ")),p.asDestroyStripes=e.slice());e=[];t=this.getElementsByTagName("thead");0!==t.length&&(da(p.aoHeader,t[0]),e=ra(p));if(null===g.aoColumns){t=[];j=0;for(i=e.length;j<i;j++)t.push(null)}else t=g.aoColumns;j=0;for(i=t.length;j<i;j++)Da(p,e?e[j]:null);hb(p,g.aoColumnDefs,t,function(a,b){ja(p,a,b)});if(x.length){var w=function(a,b){return a.getAttribute("data-"+b)!==null?b:null};h(x[0]).children("th, td").each(function(a,b){var c=p.aoColumns[a];if(c.mData===
|
102 |
+
a){var d=w(b,"sort")||w(b,"order"),e=w(b,"filter")||w(b,"search");if(d!==null||e!==null){c.mData={_:a+".display",sort:d!==null?a+".@data-"+d:k,type:d!==null?a+".@data-"+d:k,filter:e!==null?a+".@data-"+e:k};ja(p,a)}}})}var T=p.oFeatures,e=function(){if(g.aaSorting===k){var a=p.aaSorting;j=0;for(i=a.length;j<i;j++)a[j][1]=p.aoColumns[j].asSorting[0]}wa(p);T.bSort&&z(p,"aoDrawCallback",function(){if(p.bSorted){var a=V(p),b={};h.each(a,function(a,c){b[c.src]=c.dir});r(p,null,"order",[p,a,b]);Hb(p)}});
|
103 |
+
z(p,"aoDrawCallback",function(){(p.bSorted||y(p)==="ssp"||T.bDeferRender)&&wa(p)},"sc");var a=q.children("caption").each(function(){this._captionSide=h(this).css("caption-side")}),b=q.children("thead");b.length===0&&(b=h("<thead/>").appendTo(q));p.nTHead=b[0];b=q.children("tbody");b.length===0&&(b=h("<tbody/>").appendTo(q));p.nTBody=b[0];b=q.children("tfoot");if(b.length===0&&a.length>0&&(p.oScroll.sX!==""||p.oScroll.sY!==""))b=h("<tfoot/>").appendTo(q);if(b.length===0||b.children().length===0)q.addClass(u.sNoFooter);
|
104 |
+
else if(b.length>0){p.nTFoot=b[0];da(p.aoFooter,p.nTFoot)}if(g.aaData)for(j=0;j<g.aaData.length;j++)M(p,g.aaData[j]);else(p.bDeferLoading||y(p)=="dom")&&ma(p,h(p.nTBody).children("tr"));p.aiDisplay=p.aiDisplayMaster.slice();p.bInitialised=true;n===false&&ga(p)};g.bStateSave?(T.bStateSave=!0,z(p,"aoDrawCallback",xa,"state_save"),Ib(p,g,e)):e()}});b=null;return this},x,s,o,u,Xa={},Mb=/[\r\n]/g,Aa=/<.*?>/g,Zb=/^\d{2,4}[\.\/\-]\d{1,2}[\.\/\-]\d{1,2}([T ]{1}\d{1,2}[:\.]\d{2}([\.:]\d{2})?)?$/,$b=RegExp("(\\/|\\.|\\*|\\+|\\?|\\||\\(|\\)|\\[|\\]|\\{|\\}|\\\\|\\$|\\^|\\-)",
|
105 |
+
"g"),Wa=/[',$£€¥%\u2009\u202F\u20BD\u20a9\u20BArfk]/gi,L=function(a){return!a||!0===a||"-"===a?!0:!1},Nb=function(a){var b=parseInt(a,10);return!isNaN(b)&&isFinite(a)?b:null},Ob=function(a,b){Xa[b]||(Xa[b]=RegExp(Pa(b),"g"));return"string"===typeof a&&"."!==b?a.replace(/\./g,"").replace(Xa[b],"."):a},Ya=function(a,b,c){var d="string"===typeof a;if(L(a))return!0;b&&d&&(a=Ob(a,b));c&&d&&(a=a.replace(Wa,""));return!isNaN(parseFloat(a))&&isFinite(a)},Pb=function(a,b,c){return L(a)?!0:!(L(a)||"string"===
|
106 |
+
typeof a)?null:Ya(a.replace(Aa,""),b,c)?!0:null},D=function(a,b,c){var d=[],e=0,f=a.length;if(c!==k)for(;e<f;e++)a[e]&&a[e][b]&&d.push(a[e][b][c]);else for(;e<f;e++)a[e]&&d.push(a[e][b]);return d},ia=function(a,b,c,d){var e=[],f=0,g=b.length;if(d!==k)for(;f<g;f++)a[b[f]][c]&&e.push(a[b[f]][c][d]);else for(;f<g;f++)e.push(a[b[f]][c]);return e},W=function(a,b){var c=[],d;b===k?(b=0,d=a):(d=b,b=a);for(var e=b;e<d;e++)c.push(e);return c},Qb=function(a){for(var b=[],c=0,d=a.length;c<d;c++)a[c]&&b.push(a[c]);
|
107 |
+
return b},qa=function(a){var b;a:{if(!(2>a.length)){b=a.slice().sort();for(var c=b[0],d=1,e=b.length;d<e;d++){if(b[d]===c){b=!1;break a}c=b[d]}}b=!0}if(b)return a.slice();b=[];var e=a.length,f,g=0,d=0;a:for(;d<e;d++){c=a[d];for(f=0;f<g;f++)if(b[f]===c)continue a;b.push(c);g++}return b};m.util={throttle:function(a,b){var c=b!==k?b:200,d,e;return function(){var b=this,g=+new Date,j=arguments;d&&g<d+c?(clearTimeout(e),e=setTimeout(function(){d=k;a.apply(b,j)},c)):(d=g,a.apply(b,j))}},escapeRegex:function(a){return a.replace($b,
|
108 |
+
"\\$1")}};var A=function(a,b,c){a[b]!==k&&(a[c]=a[b])},ba=/\[.*?\]$/,U=/\(\)$/,Pa=m.util.escapeRegex,va=h("<div>")[0],Wb=va.textContent!==k,Yb=/<.*?>/g,Na=m.util.throttle,Rb=[],w=Array.prototype,ac=function(a){var b,c,d=m.settings,e=h.map(d,function(a){return a.nTable});if(a){if(a.nTable&&a.oApi)return[a];if(a.nodeName&&"table"===a.nodeName.toLowerCase())return b=h.inArray(a,e),-1!==b?[d[b]]:null;if(a&&"function"===typeof a.settings)return a.settings().toArray();"string"===typeof a?c=h(a):a instanceof
|
109 |
+
h&&(c=a)}else return[];if(c)return c.map(function(){b=h.inArray(this,e);return-1!==b?d[b]:null}).toArray()};s=function(a,b){if(!(this instanceof s))return new s(a,b);var c=[],d=function(a){(a=ac(a))&&(c=c.concat(a))};if(h.isArray(a))for(var e=0,f=a.length;e<f;e++)d(a[e]);else d(a);this.context=qa(c);b&&h.merge(this,b);this.selector={rows:null,cols:null,opts:null};s.extend(this,this,Rb)};m.Api=s;h.extend(s.prototype,{any:function(){return 0!==this.count()},concat:w.concat,context:[],count:function(){return this.flatten().length},
|
110 |
+
each:function(a){for(var b=0,c=this.length;b<c;b++)a.call(this,this[b],b,this);return this},eq:function(a){var b=this.context;return b.length>a?new s(b[a],this[a]):null},filter:function(a){var b=[];if(w.filter)b=w.filter.call(this,a,this);else for(var c=0,d=this.length;c<d;c++)a.call(this,this[c],c,this)&&b.push(this[c]);return new s(this.context,b)},flatten:function(){var a=[];return new s(this.context,a.concat.apply(a,this.toArray()))},join:w.join,indexOf:w.indexOf||function(a,b){for(var c=b||0,
|
111 |
+
d=this.length;c<d;c++)if(this[c]===a)return c;return-1},iterator:function(a,b,c,d){var e=[],f,g,j,h,n,l=this.context,m,o,u=this.selector;"string"===typeof a&&(d=c,c=b,b=a,a=!1);g=0;for(j=l.length;g<j;g++){var r=new s(l[g]);if("table"===b)f=c.call(r,l[g],g),f!==k&&e.push(f);else if("columns"===b||"rows"===b)f=c.call(r,l[g],this[g],g),f!==k&&e.push(f);else if("column"===b||"column-rows"===b||"row"===b||"cell"===b){o=this[g];"column-rows"===b&&(m=Ba(l[g],u.opts));h=0;for(n=o.length;h<n;h++)f=o[h],f=
|
112 |
+
"cell"===b?c.call(r,l[g],f.row,f.column,g,h):c.call(r,l[g],f,g,h,m),f!==k&&e.push(f)}}return e.length||d?(a=new s(l,a?e.concat.apply([],e):e),b=a.selector,b.rows=u.rows,b.cols=u.cols,b.opts=u.opts,a):this},lastIndexOf:w.lastIndexOf||function(a,b){return this.indexOf.apply(this.toArray.reverse(),arguments)},length:0,map:function(a){var b=[];if(w.map)b=w.map.call(this,a,this);else for(var c=0,d=this.length;c<d;c++)b.push(a.call(this,this[c],c));return new s(this.context,b)},pluck:function(a){return this.map(function(b){return b[a]})},
|
113 |
+
pop:w.pop,push:w.push,reduce:w.reduce||function(a,b){return gb(this,a,b,0,this.length,1)},reduceRight:w.reduceRight||function(a,b){return gb(this,a,b,this.length-1,-1,-1)},reverse:w.reverse,selector:null,shift:w.shift,slice:function(){return new s(this.context,this)},sort:w.sort,splice:w.splice,toArray:function(){return w.slice.call(this)},to$:function(){return h(this)},toJQuery:function(){return h(this)},unique:function(){return new s(this.context,qa(this))},unshift:w.unshift});s.extend=function(a,
|
114 |
+
b,c){if(c.length&&b&&(b instanceof s||b.__dt_wrapper)){var d,e,f,g=function(a,b,c){return function(){var d=b.apply(a,arguments);s.extend(d,d,c.methodExt);return d}};d=0;for(e=c.length;d<e;d++)f=c[d],b[f.name]="function"===typeof f.val?g(a,f.val,f):h.isPlainObject(f.val)?{}:f.val,b[f.name].__dt_wrapper=!0,s.extend(a,b[f.name],f.propExt)}};s.register=o=function(a,b){if(h.isArray(a))for(var c=0,d=a.length;c<d;c++)s.register(a[c],b);else for(var e=a.split("."),f=Rb,g,j,c=0,d=e.length;c<d;c++){g=(j=-1!==
|
115 |
+
e[c].indexOf("()"))?e[c].replace("()",""):e[c];var i;a:{i=0;for(var n=f.length;i<n;i++)if(f[i].name===g){i=f[i];break a}i=null}i||(i={name:g,val:{},methodExt:[],propExt:[]},f.push(i));c===d-1?i.val=b:f=j?i.methodExt:i.propExt}};s.registerPlural=u=function(a,b,c){s.register(a,c);s.register(b,function(){var a=c.apply(this,arguments);return a===this?this:a instanceof s?a.length?h.isArray(a[0])?new s(a.context,a[0]):a[0]:k:a})};o("tables()",function(a){var b;if(a){b=s;var c=this.context;if("number"===
|
116 |
+
typeof a)a=[c[a]];else var d=h.map(c,function(a){return a.nTable}),a=h(d).filter(a).map(function(){var a=h.inArray(this,d);return c[a]}).toArray();b=new b(a)}else b=this;return b});o("table()",function(a){var a=this.tables(a),b=a.context;return b.length?new s(b[0]):a});u("tables().nodes()","table().node()",function(){return this.iterator("table",function(a){return a.nTable},1)});u("tables().body()","table().body()",function(){return this.iterator("table",function(a){return a.nTBody},1)});u("tables().header()",
|
117 |
+
"table().header()",function(){return this.iterator("table",function(a){return a.nTHead},1)});u("tables().footer()","table().footer()",function(){return this.iterator("table",function(a){return a.nTFoot},1)});u("tables().containers()","table().container()",function(){return this.iterator("table",function(a){return a.nTableWrapper},1)});o("draw()",function(a){return this.iterator("table",function(b){"page"===a?N(b):("string"===typeof a&&(a="full-hold"===a?!1:!0),S(b,!1===a))})});o("page()",function(a){return a===
|
118 |
+
k?this.page.info().page:this.iterator("table",function(b){Sa(b,a)})});o("page.info()",function(){if(0===this.context.length)return k;var a=this.context[0],b=a._iDisplayStart,c=a.oFeatures.bPaginate?a._iDisplayLength:-1,d=a.fnRecordsDisplay(),e=-1===c;return{page:e?0:Math.floor(b/c),pages:e?1:Math.ceil(d/c),start:b,end:a.fnDisplayEnd(),length:c,recordsTotal:a.fnRecordsTotal(),recordsDisplay:d,serverSide:"ssp"===y(a)}});o("page.len()",function(a){return a===k?0!==this.context.length?this.context[0]._iDisplayLength:
|
119 |
+
k:this.iterator("table",function(b){Qa(b,a)})});var Sb=function(a,b,c){if(c){var d=new s(a);d.one("draw",function(){c(d.ajax.json())})}if("ssp"==y(a))S(a,b);else{C(a,!0);var e=a.jqXHR;e&&4!==e.readyState&&e.abort();sa(a,[],function(c){na(a);for(var c=ta(a,c),d=0,e=c.length;d<e;d++)M(a,c[d]);S(a,b);C(a,!1)})}};o("ajax.json()",function(){var a=this.context;if(0<a.length)return a[0].json});o("ajax.params()",function(){var a=this.context;if(0<a.length)return a[0].oAjaxData});o("ajax.reload()",function(a,
|
120 |
+
b){return this.iterator("table",function(c){Sb(c,!1===b,a)})});o("ajax.url()",function(a){var b=this.context;if(a===k){if(0===b.length)return k;b=b[0];return b.ajax?h.isPlainObject(b.ajax)?b.ajax.url:b.ajax:b.sAjaxSource}return this.iterator("table",function(b){h.isPlainObject(b.ajax)?b.ajax.url=a:b.ajax=a})});o("ajax.url().load()",function(a,b){return this.iterator("table",function(c){Sb(c,!1===b,a)})});var Za=function(a,b,c,d,e){var f=[],g,j,i,n,l,m;i=typeof b;if(!b||"string"===i||"function"===
|
121 |
+
i||b.length===k)b=[b];i=0;for(n=b.length;i<n;i++){j=b[i]&&b[i].split&&!b[i].match(/[\[\(:]/)?b[i].split(","):[b[i]];l=0;for(m=j.length;l<m;l++)(g=c("string"===typeof j[l]?h.trim(j[l]):j[l]))&&g.length&&(f=f.concat(g))}a=x.selector[a];if(a.length){i=0;for(n=a.length;i<n;i++)f=a[i](d,e,f)}return qa(f)},$a=function(a){a||(a={});a.filter&&a.search===k&&(a.search=a.filter);return h.extend({search:"none",order:"current",page:"all"},a)},ab=function(a){for(var b=0,c=a.length;b<c;b++)if(0<a[b].length)return a[0]=
|
122 |
+
a[b],a[0].length=1,a.length=1,a.context=[a.context[b]],a;a.length=0;return a},Ba=function(a,b){var c,d,e,f=[],g=a.aiDisplay;c=a.aiDisplayMaster;var j=b.search;d=b.order;e=b.page;if("ssp"==y(a))return"removed"===j?[]:W(0,c.length);if("current"==e){c=a._iDisplayStart;for(d=a.fnDisplayEnd();c<d;c++)f.push(g[c])}else if("current"==d||"applied"==d)f="none"==j?c.slice():"applied"==j?g.slice():h.map(c,function(a){return-1===h.inArray(a,g)?a:null});else if("index"==d||"original"==d){c=0;for(d=a.aoData.length;c<
|
123 |
+
d;c++)"none"==j?f.push(c):(e=h.inArray(c,g),(-1===e&&"removed"==j||0<=e&&"applied"==j)&&f.push(c))}return f};o("rows()",function(a,b){a===k?a="":h.isPlainObject(a)&&(b=a,a="");var b=$a(b),c=this.iterator("table",function(c){var e=b,f;return Za("row",a,function(a){var b=Nb(a);if(b!==null&&!e)return[b];f||(f=Ba(c,e));if(b!==null&&h.inArray(b,f)!==-1)return[b];if(a===null||a===k||a==="")return f;if(typeof a==="function")return h.map(f,function(b){var e=c.aoData[b];return a(b,e._aData,e.nTr)?b:null});
|
124 |
+
b=Qb(ia(c.aoData,f,"nTr"));if(a.nodeName){if(a._DT_RowIndex!==k)return[a._DT_RowIndex];if(a._DT_CellIndex)return[a._DT_CellIndex.row];b=h(a).closest("*[data-dt-row]");return b.length?[b.data("dt-row")]:[]}if(typeof a==="string"&&a.charAt(0)==="#"){var i=c.aIds[a.replace(/^#/,"")];if(i!==k)return[i.idx]}return h(b).filter(a).map(function(){return this._DT_RowIndex}).toArray()},c,e)},1);c.selector.rows=a;c.selector.opts=b;return c});o("rows().nodes()",function(){return this.iterator("row",function(a,
|
125 |
+
b){return a.aoData[b].nTr||k},1)});o("rows().data()",function(){return this.iterator(!0,"rows",function(a,b){return ia(a.aoData,b,"_aData")},1)});u("rows().cache()","row().cache()",function(a){return this.iterator("row",function(b,c){var d=b.aoData[c];return"search"===a?d._aFilterData:d._aSortData},1)});u("rows().invalidate()","row().invalidate()",function(a){return this.iterator("row",function(b,c){ca(b,c,a)})});u("rows().indexes()","row().index()",function(){return this.iterator("row",function(a,
|
126 |
+
b){return b},1)});u("rows().ids()","row().id()",function(a){for(var b=[],c=this.context,d=0,e=c.length;d<e;d++)for(var f=0,g=this[d].length;f<g;f++){var h=c[d].rowIdFn(c[d].aoData[this[d][f]]._aData);b.push((!0===a?"#":"")+h)}return new s(c,b)});u("rows().remove()","row().remove()",function(){var a=this;this.iterator("row",function(b,c,d){var e=b.aoData,f=e[c],g,h,i,n,l;e.splice(c,1);g=0;for(h=e.length;g<h;g++)if(i=e[g],l=i.anCells,null!==i.nTr&&(i.nTr._DT_RowIndex=g),null!==l){i=0;for(n=l.length;i<
|
127 |
+
n;i++)l[i]._DT_CellIndex.row=g}oa(b.aiDisplayMaster,c);oa(b.aiDisplay,c);oa(a[d],c,!1);0<b._iRecordsDisplay&&b._iRecordsDisplay--;Ra(b);c=b.rowIdFn(f._aData);c!==k&&delete b.aIds[c]});this.iterator("table",function(a){for(var c=0,d=a.aoData.length;c<d;c++)a.aoData[c].idx=c});return this});o("rows.add()",function(a){var b=this.iterator("table",function(b){var c,f,g,h=[];f=0;for(g=a.length;f<g;f++)c=a[f],c.nodeName&&"TR"===c.nodeName.toUpperCase()?h.push(ma(b,c)[0]):h.push(M(b,c));return h},1),c=this.rows(-1);
|
128 |
+
c.pop();h.merge(c,b);return c});o("row()",function(a,b){return ab(this.rows(a,b))});o("row().data()",function(a){var b=this.context;if(a===k)return b.length&&this.length?b[0].aoData[this[0]]._aData:k;b[0].aoData[this[0]]._aData=a;ca(b[0],this[0],"data");return this});o("row().node()",function(){var a=this.context;return a.length&&this.length?a[0].aoData[this[0]].nTr||null:null});o("row.add()",function(a){a instanceof h&&a.length&&(a=a[0]);var b=this.iterator("table",function(b){return a.nodeName&&
|
129 |
+
"TR"===a.nodeName.toUpperCase()?ma(b,a)[0]:M(b,a)});return this.row(b[0])});var bb=function(a,b){var c=a.context;if(c.length&&(c=c[0].aoData[b!==k?b:a[0]])&&c._details)c._details.remove(),c._detailsShow=k,c._details=k},Tb=function(a,b){var c=a.context;if(c.length&&a.length){var d=c[0].aoData[a[0]];if(d._details){(d._detailsShow=b)?d._details.insertAfter(d.nTr):d._details.detach();var e=c[0],f=new s(e),g=e.aoData;f.off("draw.dt.DT_details column-visibility.dt.DT_details destroy.dt.DT_details");0<D(g,
|
130 |
+
"_details").length&&(f.on("draw.dt.DT_details",function(a,b){e===b&&f.rows({page:"current"}).eq(0).each(function(a){a=g[a];a._detailsShow&&a._details.insertAfter(a.nTr)})}),f.on("column-visibility.dt.DT_details",function(a,b){if(e===b)for(var c,d=aa(b),f=0,h=g.length;f<h;f++)c=g[f],c._details&&c._details.children("td[colspan]").attr("colspan",d)}),f.on("destroy.dt.DT_details",function(a,b){if(e===b)for(var c=0,d=g.length;c<d;c++)g[c]._details&&bb(f,c)}))}}};o("row().child()",function(a,b){var c=this.context;
|
131 |
+
if(a===k)return c.length&&this.length?c[0].aoData[this[0]]._details:k;if(!0===a)this.child.show();else if(!1===a)bb(this);else if(c.length&&this.length){var d=c[0],c=c[0].aoData[this[0]],e=[],f=function(a,b){if(h.isArray(a)||a instanceof h)for(var c=0,k=a.length;c<k;c++)f(a[c],b);else a.nodeName&&"tr"===a.nodeName.toLowerCase()?e.push(a):(c=h("<tr><td/></tr>").addClass(b),h("td",c).addClass(b).html(a)[0].colSpan=aa(d),e.push(c[0]))};f(a,b);c._details&&c._details.detach();c._details=h(e);c._detailsShow&&
|
132 |
+
c._details.insertAfter(c.nTr)}return this});o(["row().child.show()","row().child().show()"],function(){Tb(this,!0);return this});o(["row().child.hide()","row().child().hide()"],function(){Tb(this,!1);return this});o(["row().child.remove()","row().child().remove()"],function(){bb(this);return this});o("row().child.isShown()",function(){var a=this.context;return a.length&&this.length?a[0].aoData[this[0]]._detailsShow||!1:!1});var bc=/^([^:]+):(name|visIdx|visible)$/,Ub=function(a,b,c,d,e){for(var c=
|
133 |
+
[],d=0,f=e.length;d<f;d++)c.push(B(a,e[d],b));return c};o("columns()",function(a,b){a===k?a="":h.isPlainObject(a)&&(b=a,a="");var b=$a(b),c=this.iterator("table",function(c){var e=a,f=b,g=c.aoColumns,j=D(g,"sName"),i=D(g,"nTh");return Za("column",e,function(a){var b=Nb(a);if(a==="")return W(g.length);if(b!==null)return[b>=0?b:g.length+b];if(typeof a==="function"){var e=Ba(c,f);return h.map(g,function(b,f){return a(f,Ub(c,f,0,0,e),i[f])?f:null})}var k=typeof a==="string"?a.match(bc):"";if(k)switch(k[2]){case "visIdx":case "visible":b=
|
134 |
+
parseInt(k[1],10);if(b<0){var m=h.map(g,function(a,b){return a.bVisible?b:null});return[m[m.length+b]]}return[Z(c,b)];case "name":return h.map(j,function(a,b){return a===k[1]?b:null});default:return[]}if(a.nodeName&&a._DT_CellIndex)return[a._DT_CellIndex.column];b=h(i).filter(a).map(function(){return h.inArray(this,i)}).toArray();if(b.length||!a.nodeName)return b;b=h(a).closest("*[data-dt-column]");return b.length?[b.data("dt-column")]:[]},c,f)},1);c.selector.cols=a;c.selector.opts=b;return c});u("columns().header()",
|
135 |
+
"column().header()",function(){return this.iterator("column",function(a,b){return a.aoColumns[b].nTh},1)});u("columns().footer()","column().footer()",function(){return this.iterator("column",function(a,b){return a.aoColumns[b].nTf},1)});u("columns().data()","column().data()",function(){return this.iterator("column-rows",Ub,1)});u("columns().dataSrc()","column().dataSrc()",function(){return this.iterator("column",function(a,b){return a.aoColumns[b].mData},1)});u("columns().cache()","column().cache()",
|
136 |
+
function(a){return this.iterator("column-rows",function(b,c,d,e,f){return ia(b.aoData,f,"search"===a?"_aFilterData":"_aSortData",c)},1)});u("columns().nodes()","column().nodes()",function(){return this.iterator("column-rows",function(a,b,c,d,e){return ia(a.aoData,e,"anCells",b)},1)});u("columns().visible()","column().visible()",function(a,b){var c=this.iterator("column",function(b,c){if(a===k)return b.aoColumns[c].bVisible;var f=b.aoColumns,g=f[c],j=b.aoData,i,n,l;if(a!==k&&g.bVisible!==a){if(a){var m=
|
137 |
+
h.inArray(!0,D(f,"bVisible"),c+1);i=0;for(n=j.length;i<n;i++)l=j[i].nTr,f=j[i].anCells,l&&l.insertBefore(f[c],f[m]||null)}else h(D(b.aoData,"anCells",c)).detach();g.bVisible=a;ea(b,b.aoHeader);ea(b,b.aoFooter);xa(b)}});a!==k&&(this.iterator("column",function(c,e){r(c,null,"column-visibility",[c,e,a,b])}),(b===k||b)&&this.columns.adjust());return c});u("columns().indexes()","column().index()",function(a){return this.iterator("column",function(b,c){return"visible"===a?$(b,c):c},1)});o("columns.adjust()",
|
138 |
+
function(){return this.iterator("table",function(a){Y(a)},1)});o("column.index()",function(a,b){if(0!==this.context.length){var c=this.context[0];if("fromVisible"===a||"toData"===a)return Z(c,b);if("fromData"===a||"toVisible"===a)return $(c,b)}});o("column()",function(a,b){return ab(this.columns(a,b))});o("cells()",function(a,b,c){h.isPlainObject(a)&&(a.row===k?(c=a,a=null):(c=b,b=null));h.isPlainObject(b)&&(c=b,b=null);if(null===b||b===k)return this.iterator("table",function(b){var d=a,e=$a(c),f=
|
139 |
+
b.aoData,g=Ba(b,e),j=Qb(ia(f,g,"anCells")),i=h([].concat.apply([],j)),l,n=b.aoColumns.length,m,o,u,s,r,v;return Za("cell",d,function(a){var c=typeof a==="function";if(a===null||a===k||c){m=[];o=0;for(u=g.length;o<u;o++){l=g[o];for(s=0;s<n;s++){r={row:l,column:s};if(c){v=f[l];a(r,B(b,l,s),v.anCells?v.anCells[s]:null)&&m.push(r)}else m.push(r)}}return m}if(h.isPlainObject(a))return[a];c=i.filter(a).map(function(a,b){return{row:b._DT_CellIndex.row,column:b._DT_CellIndex.column}}).toArray();if(c.length||
|
140 |
+
!a.nodeName)return c;v=h(a).closest("*[data-dt-row]");return v.length?[{row:v.data("dt-row"),column:v.data("dt-column")}]:[]},b,e)});var d=this.columns(b,c),e=this.rows(a,c),f,g,j,i,n,l=this.iterator("table",function(a,b){f=[];g=0;for(j=e[b].length;g<j;g++){i=0;for(n=d[b].length;i<n;i++)f.push({row:e[b][g],column:d[b][i]})}return f},1);h.extend(l.selector,{cols:b,rows:a,opts:c});return l});u("cells().nodes()","cell().node()",function(){return this.iterator("cell",function(a,b,c){return(a=a.aoData[b])&&
|
141 |
+
a.anCells?a.anCells[c]:k},1)});o("cells().data()",function(){return this.iterator("cell",function(a,b,c){return B(a,b,c)},1)});u("cells().cache()","cell().cache()",function(a){a="search"===a?"_aFilterData":"_aSortData";return this.iterator("cell",function(b,c,d){return b.aoData[c][a][d]},1)});u("cells().render()","cell().render()",function(a){return this.iterator("cell",function(b,c,d){return B(b,c,d,a)},1)});u("cells().indexes()","cell().index()",function(){return this.iterator("cell",function(a,
|
142 |
+
b,c){return{row:b,column:c,columnVisible:$(a,c)}},1)});u("cells().invalidate()","cell().invalidate()",function(a){return this.iterator("cell",function(b,c,d){ca(b,c,a,d)})});o("cell()",function(a,b,c){return ab(this.cells(a,b,c))});o("cell().data()",function(a){var b=this.context,c=this[0];if(a===k)return b.length&&c.length?B(b[0],c[0].row,c[0].column):k;ib(b[0],c[0].row,c[0].column,a);ca(b[0],c[0].row,"data",c[0].column);return this});o("order()",function(a,b){var c=this.context;if(a===k)return 0!==
|
143 |
+
c.length?c[0].aaSorting:k;"number"===typeof a?a=[[a,b]]:a.length&&!h.isArray(a[0])&&(a=Array.prototype.slice.call(arguments));return this.iterator("table",function(b){b.aaSorting=a.slice()})});o("order.listener()",function(a,b,c){return this.iterator("table",function(d){La(d,a,b,c)})});o("order.fixed()",function(a){if(!a){var b=this.context,b=b.length?b[0].aaSortingFixed:k;return h.isArray(b)?{pre:b}:b}return this.iterator("table",function(b){b.aaSortingFixed=h.extend(!0,{},a)})});o(["columns().order()",
|
144 |
+
"column().order()"],function(a){var b=this;return this.iterator("table",function(c,d){var e=[];h.each(b[d],function(b,c){e.push([c,a])});c.aaSorting=e})});o("search()",function(a,b,c,d){var e=this.context;return a===k?0!==e.length?e[0].oPreviousSearch.sSearch:k:this.iterator("table",function(e){e.oFeatures.bFilter&&fa(e,h.extend({},e.oPreviousSearch,{sSearch:a+"",bRegex:null===b?!1:b,bSmart:null===c?!0:c,bCaseInsensitive:null===d?!0:d}),1)})});u("columns().search()","column().search()",function(a,
|
145 |
+
b,c,d){return this.iterator("column",function(e,f){var g=e.aoPreSearchCols;if(a===k)return g[f].sSearch;e.oFeatures.bFilter&&(h.extend(g[f],{sSearch:a+"",bRegex:null===b?!1:b,bSmart:null===c?!0:c,bCaseInsensitive:null===d?!0:d}),fa(e,e.oPreviousSearch,1))})});o("state()",function(){return this.context.length?this.context[0].oSavedState:null});o("state.clear()",function(){return this.iterator("table",function(a){a.fnStateSaveCallback.call(a.oInstance,a,{})})});o("state.loaded()",function(){return this.context.length?
|
146 |
+
this.context[0].oLoadedState:null});o("state.save()",function(){return this.iterator("table",function(a){xa(a)})});m.versionCheck=m.fnVersionCheck=function(a){for(var b=m.version.split("."),a=a.split("."),c,d,e=0,f=a.length;e<f;e++)if(c=parseInt(b[e],10)||0,d=parseInt(a[e],10)||0,c!==d)return c>d;return!0};m.isDataTable=m.fnIsDataTable=function(a){var b=h(a).get(0),c=!1;if(a instanceof m.Api)return!0;h.each(m.settings,function(a,e){var f=e.nScrollHead?h("table",e.nScrollHead)[0]:null,g=e.nScrollFoot?
|
147 |
+
h("table",e.nScrollFoot)[0]:null;if(e.nTable===b||f===b||g===b)c=!0});return c};m.tables=m.fnTables=function(a){var b=!1;h.isPlainObject(a)&&(b=a.api,a=a.visible);var c=h.map(m.settings,function(b){if(!a||a&&h(b.nTable).is(":visible"))return b.nTable});return b?new s(c):c};m.camelToHungarian=I;o("$()",function(a,b){var c=this.rows(b).nodes(),c=h(c);return h([].concat(c.filter(a).toArray(),c.find(a).toArray()))});h.each(["on","one","off"],function(a,b){o(b+"()",function(){var a=Array.prototype.slice.call(arguments);
|
148 |
+
a[0]=h.map(a[0].split(/\s/),function(a){return!a.match(/\.dt\b/)?a+".dt":a}).join(" ");var d=h(this.tables().nodes());d[b].apply(d,a);return this})});o("clear()",function(){return this.iterator("table",function(a){na(a)})});o("settings()",function(){return new s(this.context,this.context)});o("init()",function(){var a=this.context;return a.length?a[0].oInit:null});o("data()",function(){return this.iterator("table",function(a){return D(a.aoData,"_aData")}).flatten()});o("destroy()",function(a){a=a||
|
149 |
+
!1;return this.iterator("table",function(b){var c=b.nTableWrapper.parentNode,d=b.oClasses,e=b.nTable,f=b.nTBody,g=b.nTHead,j=b.nTFoot,i=h(e),f=h(f),k=h(b.nTableWrapper),l=h.map(b.aoData,function(a){return a.nTr}),o;b.bDestroying=!0;r(b,"aoDestroyCallback","destroy",[b]);a||(new s(b)).columns().visible(!0);k.off(".DT").find(":not(tbody *)").off(".DT");h(E).off(".DT-"+b.sInstance);e!=g.parentNode&&(i.children("thead").detach(),i.append(g));j&&e!=j.parentNode&&(i.children("tfoot").detach(),i.append(j));
|
150 |
+
b.aaSorting=[];b.aaSortingFixed=[];wa(b);h(l).removeClass(b.asStripeClasses.join(" "));h("th, td",g).removeClass(d.sSortable+" "+d.sSortableAsc+" "+d.sSortableDesc+" "+d.sSortableNone);f.children().detach();f.append(l);g=a?"remove":"detach";i[g]();k[g]();!a&&c&&(c.insertBefore(e,b.nTableReinsertBefore),i.css("width",b.sDestroyWidth).removeClass(d.sTable),(o=b.asDestroyStripes.length)&&f.children().each(function(a){h(this).addClass(b.asDestroyStripes[a%o])}));c=h.inArray(b,m.settings);-1!==c&&m.settings.splice(c,
|
151 |
+
1)})});h.each(["column","row","cell"],function(a,b){o(b+"s().every()",function(a){var d=this.selector.opts,e=this;return this.iterator(b,function(f,g,h,i,n){a.call(e[b](g,"cell"===b?h:d,"cell"===b?d:k),g,h,i,n)})})});o("i18n()",function(a,b,c){var d=this.context[0],a=Q(a)(d.oLanguage);a===k&&(a=b);c!==k&&h.isPlainObject(a)&&(a=a[c]!==k?a[c]:a._);return a.replace("%d",c)});m.version="1.10.16";m.settings=[];m.models={};m.models.oSearch={bCaseInsensitive:!0,sSearch:"",bRegex:!1,bSmart:!0};m.models.oRow=
|
152 |
+
{nTr:null,anCells:null,_aData:[],_aSortData:null,_aFilterData:null,_sFilterRow:null,_sRowStripe:"",src:null,idx:-1};m.models.oColumn={idx:null,aDataSort:null,asSorting:null,bSearchable:null,bSortable:null,bVisible:null,_sManualType:null,_bAttrSrc:!1,fnCreatedCell:null,fnGetData:null,fnSetData:null,mData:null,mRender:null,nTh:null,nTf:null,sClass:null,sContentPadding:null,sDefaultContent:null,sName:null,sSortDataType:"std",sSortingClass:null,sSortingClassJUI:null,sTitle:null,sType:null,sWidth:null,
|
153 |
+
sWidthOrig:null};m.defaults={aaData:null,aaSorting:[[0,"asc"]],aaSortingFixed:[],ajax:null,aLengthMenu:[10,25,50,100],aoColumns:null,aoColumnDefs:null,aoSearchCols:[],asStripeClasses:null,bAutoWidth:!0,bDeferRender:!1,bDestroy:!1,bFilter:!0,bInfo:!0,bLengthChange:!0,bPaginate:!0,bProcessing:!1,bRetrieve:!1,bScrollCollapse:!1,bServerSide:!1,bSort:!0,bSortMulti:!0,bSortCellsTop:!1,bSortClasses:!0,bStateSave:!1,fnCreatedRow:null,fnDrawCallback:null,fnFooterCallback:null,fnFormatNumber:function(a){return a.toString().replace(/\B(?=(\d{3})+(?!\d))/g,
|
154 |
+
this.oLanguage.sThousands)},fnHeaderCallback:null,fnInfoCallback:null,fnInitComplete:null,fnPreDrawCallback:null,fnRowCallback:null,fnServerData:null,fnServerParams:null,fnStateLoadCallback:function(a){try{return JSON.parse((-1===a.iStateDuration?sessionStorage:localStorage).getItem("DataTables_"+a.sInstance+"_"+location.pathname))}catch(b){}},fnStateLoadParams:null,fnStateLoaded:null,fnStateSaveCallback:function(a,b){try{(-1===a.iStateDuration?sessionStorage:localStorage).setItem("DataTables_"+a.sInstance+
|
155 |
+
"_"+location.pathname,JSON.stringify(b))}catch(c){}},fnStateSaveParams:null,iStateDuration:7200,iDeferLoading:null,iDisplayLength:10,iDisplayStart:0,iTabIndex:0,oClasses:{},oLanguage:{oAria:{sSortAscending:": activate to sort column ascending",sSortDescending:": activate to sort column descending"},oPaginate:{sFirst:"First",sLast:"Last",sNext:"Next",sPrevious:"Previous"},sEmptyTable:"No data available in table",sInfo:"Showing _START_ to _END_ of _TOTAL_ entries",sInfoEmpty:"Showing 0 to 0 of 0 entries",
|
156 |
+
sInfoFiltered:"(filtered from _MAX_ total entries)",sInfoPostFix:"",sDecimal:"",sThousands:",",sLengthMenu:"Show _MENU_ entries",sLoadingRecords:"Loading...",sProcessing:"Processing...",sSearch:"Search:",sSearchPlaceholder:"",sUrl:"",sZeroRecords:"No matching records found"},oSearch:h.extend({},m.models.oSearch),sAjaxDataProp:"data",sAjaxSource:null,sDom:"lfrtip",searchDelay:null,sPaginationType:"simple_numbers",sScrollX:"",sScrollXInner:"",sScrollY:"",sServerMethod:"GET",renderer:null,rowId:"DT_RowId"};
|
157 |
+
X(m.defaults);m.defaults.column={aDataSort:null,iDataSort:-1,asSorting:["asc","desc"],bSearchable:!0,bSortable:!0,bVisible:!0,fnCreatedCell:null,mData:null,mRender:null,sCellType:"td",sClass:"",sContentPadding:"",sDefaultContent:null,sName:"",sSortDataType:"std",sTitle:null,sType:null,sWidth:null};X(m.defaults.column);m.models.oSettings={oFeatures:{bAutoWidth:null,bDeferRender:null,bFilter:null,bInfo:null,bLengthChange:null,bPaginate:null,bProcessing:null,bServerSide:null,bSort:null,bSortMulti:null,
|
158 |
+
bSortClasses:null,bStateSave:null},oScroll:{bCollapse:null,iBarWidth:0,sX:null,sXInner:null,sY:null},oLanguage:{fnInfoCallback:null},oBrowser:{bScrollOversize:!1,bScrollbarLeft:!1,bBounding:!1,barWidth:0},ajax:null,aanFeatures:[],aoData:[],aiDisplay:[],aiDisplayMaster:[],aIds:{},aoColumns:[],aoHeader:[],aoFooter:[],oPreviousSearch:{},aoPreSearchCols:[],aaSorting:null,aaSortingFixed:[],asStripeClasses:null,asDestroyStripes:[],sDestroyWidth:0,aoRowCallback:[],aoHeaderCallback:[],aoFooterCallback:[],
|
159 |
+
aoDrawCallback:[],aoRowCreatedCallback:[],aoPreDrawCallback:[],aoInitComplete:[],aoStateSaveParams:[],aoStateLoadParams:[],aoStateLoaded:[],sTableId:"",nTable:null,nTHead:null,nTFoot:null,nTBody:null,nTableWrapper:null,bDeferLoading:!1,bInitialised:!1,aoOpenRows:[],sDom:null,searchDelay:null,sPaginationType:"two_button",iStateDuration:0,aoStateSave:[],aoStateLoad:[],oSavedState:null,oLoadedState:null,sAjaxSource:null,sAjaxDataProp:null,bAjaxDataGet:!0,jqXHR:null,json:k,oAjaxData:k,fnServerData:null,
|
160 |
+
aoServerParams:[],sServerMethod:null,fnFormatNumber:null,aLengthMenu:null,iDraw:0,bDrawing:!1,iDrawError:-1,_iDisplayLength:10,_iDisplayStart:0,_iRecordsTotal:0,_iRecordsDisplay:0,oClasses:{},bFiltered:!1,bSorted:!1,bSortCellsTop:null,oInit:null,aoDestroyCallback:[],fnRecordsTotal:function(){return"ssp"==y(this)?1*this._iRecordsTotal:this.aiDisplayMaster.length},fnRecordsDisplay:function(){return"ssp"==y(this)?1*this._iRecordsDisplay:this.aiDisplay.length},fnDisplayEnd:function(){var a=this._iDisplayLength,
|
161 |
+
b=this._iDisplayStart,c=b+a,d=this.aiDisplay.length,e=this.oFeatures,f=e.bPaginate;return e.bServerSide?!1===f||-1===a?b+d:Math.min(b+a,this._iRecordsDisplay):!f||c>d||-1===a?d:c},oInstance:null,sInstance:null,iTabIndex:0,nScrollHead:null,nScrollFoot:null,aLastSort:[],oPlugins:{},rowIdFn:null,rowId:null};m.ext=x={buttons:{},classes:{},build:"dt/dt-1.10.16/af-2.2.2/b-1.5.1/cr-1.4.1/fc-3.2.4/fh-3.1.3/kt-2.3.2/r-2.2.1/rr-1.2.3/sc-1.4.4/sl-1.2.5",errMode:"alert",feature:[],search:[],selector:{cell:[],column:[],row:[]},internal:{},legacy:{ajax:null},pager:{},renderer:{pageButton:{},header:{}},
|
162 |
+
order:{},type:{detect:[],search:{},order:{}},_unique:0,fnVersionCheck:m.fnVersionCheck,iApiIndex:0,oJUIClasses:{},sVersion:m.version};h.extend(x,{afnFiltering:x.search,aTypes:x.type.detect,ofnSearch:x.type.search,oSort:x.type.order,afnSortData:x.order,aoFeatures:x.feature,oApi:x.internal,oStdClasses:x.classes,oPagination:x.pager});h.extend(m.ext.classes,{sTable:"dataTable",sNoFooter:"no-footer",sPageButton:"paginate_button",sPageButtonActive:"current",sPageButtonDisabled:"disabled",sStripeOdd:"odd",
|
163 |
+
sStripeEven:"even",sRowEmpty:"dataTables_empty",sWrapper:"dataTables_wrapper",sFilter:"dataTables_filter",sInfo:"dataTables_info",sPaging:"dataTables_paginate paging_",sLength:"dataTables_length",sProcessing:"dataTables_processing",sSortAsc:"sorting_asc",sSortDesc:"sorting_desc",sSortable:"sorting",sSortableAsc:"sorting_asc_disabled",sSortableDesc:"sorting_desc_disabled",sSortableNone:"sorting_disabled",sSortColumn:"sorting_",sFilterInput:"",sLengthSelect:"",sScrollWrapper:"dataTables_scroll",sScrollHead:"dataTables_scrollHead",
|
164 |
+
sScrollHeadInner:"dataTables_scrollHeadInner",sScrollBody:"dataTables_scrollBody",sScrollFoot:"dataTables_scrollFoot",sScrollFootInner:"dataTables_scrollFootInner",sHeaderTH:"",sFooterTH:"",sSortJUIAsc:"",sSortJUIDesc:"",sSortJUI:"",sSortJUIAscAllowed:"",sSortJUIDescAllowed:"",sSortJUIWrapper:"",sSortIcon:"",sJUIHeader:"",sJUIFooter:""});var Kb=m.ext.pager;h.extend(Kb,{simple:function(){return["previous","next"]},full:function(){return["first","previous","next","last"]},numbers:function(a,b){return[ha(a,
|
165 |
+
b)]},simple_numbers:function(a,b){return["previous",ha(a,b),"next"]},full_numbers:function(a,b){return["first","previous",ha(a,b),"next","last"]},first_last_numbers:function(a,b){return["first",ha(a,b),"last"]},_numbers:ha,numbers_length:7});h.extend(!0,m.ext.renderer,{pageButton:{_:function(a,b,c,d,e,f){var g=a.oClasses,j=a.oLanguage.oPaginate,i=a.oLanguage.oAria.paginate||{},n,l,m=0,o=function(b,d){var k,s,u,r,v=function(b){Sa(a,b.data.action,true)};k=0;for(s=d.length;k<s;k++){r=d[k];if(h.isArray(r)){u=
|
166 |
+
h("<"+(r.DT_el||"div")+"/>").appendTo(b);o(u,r)}else{n=null;l="";switch(r){case "ellipsis":b.append('<span class="ellipsis">…</span>');break;case "first":n=j.sFirst;l=r+(e>0?"":" "+g.sPageButtonDisabled);break;case "previous":n=j.sPrevious;l=r+(e>0?"":" "+g.sPageButtonDisabled);break;case "next":n=j.sNext;l=r+(e<f-1?"":" "+g.sPageButtonDisabled);break;case "last":n=j.sLast;l=r+(e<f-1?"":" "+g.sPageButtonDisabled);break;default:n=r+1;l=e===r?g.sPageButtonActive:""}if(n!==null){u=h("<a>",{"class":g.sPageButton+
|
167 |
+
" "+l,"aria-controls":a.sTableId,"aria-label":i[r],"data-dt-idx":m,tabindex:a.iTabIndex,id:c===0&&typeof r==="string"?a.sTableId+"_"+r:null}).html(n).appendTo(b);Va(u,{action:r},v);m++}}}},s;try{s=h(b).find(G.activeElement).data("dt-idx")}catch(u){}o(h(b).empty(),d);s!==k&&h(b).find("[data-dt-idx="+s+"]").focus()}}});h.extend(m.ext.type.detect,[function(a,b){var c=b.oLanguage.sDecimal;return Ya(a,c)?"num"+c:null},function(a){if(a&&!(a instanceof Date)&&!Zb.test(a))return null;var b=Date.parse(a);
|
168 |
+
return null!==b&&!isNaN(b)||L(a)?"date":null},function(a,b){var c=b.oLanguage.sDecimal;return Ya(a,c,!0)?"num-fmt"+c:null},function(a,b){var c=b.oLanguage.sDecimal;return Pb(a,c)?"html-num"+c:null},function(a,b){var c=b.oLanguage.sDecimal;return Pb(a,c,!0)?"html-num-fmt"+c:null},function(a){return L(a)||"string"===typeof a&&-1!==a.indexOf("<")?"html":null}]);h.extend(m.ext.type.search,{html:function(a){return L(a)?a:"string"===typeof a?a.replace(Mb," ").replace(Aa,""):""},string:function(a){return L(a)?
|
169 |
+
a:"string"===typeof a?a.replace(Mb," "):a}});var za=function(a,b,c,d){if(0!==a&&(!a||"-"===a))return-Infinity;b&&(a=Ob(a,b));a.replace&&(c&&(a=a.replace(c,"")),d&&(a=a.replace(d,"")));return 1*a};h.extend(x.type.order,{"date-pre":function(a){return Date.parse(a)||-Infinity},"html-pre":function(a){return L(a)?"":a.replace?a.replace(/<.*?>/g,"").toLowerCase():a+""},"string-pre":function(a){return L(a)?"":"string"===typeof a?a.toLowerCase():!a.toString?"":a.toString()},"string-asc":function(a,b){return a<
|
170 |
+
b?-1:a>b?1:0},"string-desc":function(a,b){return a<b?1:a>b?-1:0}});cb("");h.extend(!0,m.ext.renderer,{header:{_:function(a,b,c,d){h(a.nTable).on("order.dt.DT",function(e,f,g,h){if(a===f){e=c.idx;b.removeClass(c.sSortingClass+" "+d.sSortAsc+" "+d.sSortDesc).addClass(h[e]=="asc"?d.sSortAsc:h[e]=="desc"?d.sSortDesc:c.sSortingClass)}})},jqueryui:function(a,b,c,d){h("<div/>").addClass(d.sSortJUIWrapper).append(b.contents()).append(h("<span/>").addClass(d.sSortIcon+" "+c.sSortingClassJUI)).appendTo(b);
|
171 |
+
h(a.nTable).on("order.dt.DT",function(e,f,g,h){if(a===f){e=c.idx;b.removeClass(d.sSortAsc+" "+d.sSortDesc).addClass(h[e]=="asc"?d.sSortAsc:h[e]=="desc"?d.sSortDesc:c.sSortingClass);b.find("span."+d.sSortIcon).removeClass(d.sSortJUIAsc+" "+d.sSortJUIDesc+" "+d.sSortJUI+" "+d.sSortJUIAscAllowed+" "+d.sSortJUIDescAllowed).addClass(h[e]=="asc"?d.sSortJUIAsc:h[e]=="desc"?d.sSortJUIDesc:c.sSortingClassJUI)}})}}});var Vb=function(a){return"string"===typeof a?a.replace(/</g,"<").replace(/>/g,">").replace(/"/g,
|
172 |
+
"""):a};m.render={number:function(a,b,c,d,e){return{display:function(f){if("number"!==typeof f&&"string"!==typeof f)return f;var g=0>f?"-":"",h=parseFloat(f);if(isNaN(h))return Vb(f);h=h.toFixed(c);f=Math.abs(h);h=parseInt(f,10);f=c?b+(f-h).toFixed(c).substring(2):"";return g+(d||"")+h.toString().replace(/\B(?=(\d{3})+(?!\d))/g,a)+f+(e||"")}}},text:function(){return{display:Vb}}};h.extend(m.ext.internal,{_fnExternApiFunc:Lb,_fnBuildAjax:sa,_fnAjaxUpdate:kb,_fnAjaxParameters:tb,_fnAjaxUpdateDraw:ub,
|
173 |
+
_fnAjaxDataSrc:ta,_fnAddColumn:Da,_fnColumnOptions:ja,_fnAdjustColumnSizing:Y,_fnVisibleToColumnIndex:Z,_fnColumnIndexToVisible:$,_fnVisbleColumns:aa,_fnGetColumns:la,_fnColumnTypes:Fa,_fnApplyColumnDefs:hb,_fnHungarianMap:X,_fnCamelToHungarian:I,_fnLanguageCompat:Ca,_fnBrowserDetect:fb,_fnAddData:M,_fnAddTr:ma,_fnNodeToDataIndex:function(a,b){return b._DT_RowIndex!==k?b._DT_RowIndex:null},_fnNodeToColumnIndex:function(a,b,c){return h.inArray(c,a.aoData[b].anCells)},_fnGetCellData:B,_fnSetCellData:ib,
|
174 |
+
_fnSplitObjNotation:Ia,_fnGetObjectDataFn:Q,_fnSetObjectDataFn:R,_fnGetDataMaster:Ja,_fnClearTable:na,_fnDeleteIndex:oa,_fnInvalidate:ca,_fnGetRowElements:Ha,_fnCreateTr:Ga,_fnBuildHead:jb,_fnDrawHead:ea,_fnDraw:N,_fnReDraw:S,_fnAddOptionsHtml:mb,_fnDetectHeader:da,_fnGetUniqueThs:ra,_fnFeatureHtmlFilter:ob,_fnFilterComplete:fa,_fnFilterCustom:xb,_fnFilterColumn:wb,_fnFilter:vb,_fnFilterCreateSearch:Oa,_fnEscapeRegex:Pa,_fnFilterData:yb,_fnFeatureHtmlInfo:rb,_fnUpdateInfo:Bb,_fnInfoMacros:Cb,_fnInitialise:ga,
|
175 |
+
_fnInitComplete:ua,_fnLengthChange:Qa,_fnFeatureHtmlLength:nb,_fnFeatureHtmlPaginate:sb,_fnPageChange:Sa,_fnFeatureHtmlProcessing:pb,_fnProcessingDisplay:C,_fnFeatureHtmlTable:qb,_fnScrollDraw:ka,_fnApplyToChildren:H,_fnCalculateColumnWidths:Ea,_fnThrottle:Na,_fnConvertToWidth:Db,_fnGetWidestNode:Eb,_fnGetMaxLenString:Fb,_fnStringToCss:v,_fnSortFlatten:V,_fnSort:lb,_fnSortAria:Hb,_fnSortListener:Ua,_fnSortAttachListener:La,_fnSortingClasses:wa,_fnSortData:Gb,_fnSaveState:xa,_fnLoadState:Ib,_fnSettingsFromNode:ya,
|
176 |
+
_fnLog:J,_fnMap:F,_fnBindAction:Va,_fnCallbackReg:z,_fnCallbackFire:r,_fnLengthOverflow:Ra,_fnRenderer:Ma,_fnDataSource:y,_fnRowAttributes:Ka,_fnCalculateEnd:function(){}});h.fn.dataTable=m;m.$=h;h.fn.dataTableSettings=m.settings;h.fn.dataTableExt=m.ext;h.fn.DataTable=function(a){return h(this).dataTable(a).api()};h.each(m,function(a,b){h.fn.DataTable[a]=b});return h.fn.dataTable});
|
177 |
+
|
178 |
+
|
179 |
+
/*!
|
180 |
+
AutoFill 2.2.2
|
181 |
+
©2008-2017 SpryMedia Ltd - datatables.net/license
|
182 |
+
*/
|
183 |
+
(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(l){return e(l,window,document)}):"object"===typeof exports?module.exports=function(l,i){l||(l=window);if(!i||!i.fn.dataTable)i=require("datatables.net")(l,i).$;return e(i,l,l.document)}:e(jQuery,window,document)})(function(e,l,i,q){var k=e.fn.dataTable,p=0,j=function(c,b){if(!k.versionCheck||!k.versionCheck("1.10.8"))throw"Warning: AutoFill requires DataTables 1.10.8 or greater";this.c=e.extend(!0,{},k.defaults.autoFill,
|
184 |
+
j.defaults,b);this.s={dt:new k.Api(c),namespace:".autoFill"+p++,scroll:{},scrollInterval:null,handle:{height:0,width:0},enabled:!1};this.dom={handle:e('<div class="dt-autofill-handle"/>'),select:{top:e('<div class="dt-autofill-select top"/>'),right:e('<div class="dt-autofill-select right"/>'),bottom:e('<div class="dt-autofill-select bottom"/>'),left:e('<div class="dt-autofill-select left"/>')},background:e('<div class="dt-autofill-background"/>'),list:e('<div class="dt-autofill-list">'+this.s.dt.i18n("autoFill.info",
|
185 |
+
"")+"<ul/></div>"),dtScroll:null,offsetParent:null};this._constructor()};e.extend(j.prototype,{enabled:function(){return this.s.enabled},enable:function(c){var b=this;if(!1===c)return this.disable();this.s.enabled=!0;this._focusListener();this.dom.handle.on("mousedown",function(a){b._mousedown(a);return!1});return this},disable:function(){this.s.enabled=!1;this._focusListenerRemove();return this},_constructor:function(){var c=this,b=this.s.dt,a=e("div.dataTables_scrollBody",this.s.dt.table().container());
|
186 |
+
b.settings()[0].autoFill=this;a.length&&(this.dom.dtScroll=a,"static"===a.css("position")&&a.css("position","relative"));!1!==this.c.enable&&this.enable();b.on("destroy.autoFill",function(){c._focusListenerRemove()})},_attach:function(c){var b=this.s.dt,a=b.cell(c).index(),d=this.dom.handle,f=this.s.handle;if(!a||-1===b.columns(this.c.columns).indexes().indexOf(a.column))this._detach();else{this.dom.offsetParent||(this.dom.offsetParent=e(b.table().node()).offsetParent());if(!f.height||!f.width)d.appendTo("body"),
|
187 |
+
f.height=d.outerHeight(),f.width=d.outerWidth();b=this._getPosition(c,this.dom.offsetParent);this.dom.attachedTo=c;d.css({top:b.top+c.offsetHeight-f.height,left:b.left+c.offsetWidth-f.width}).appendTo(this.dom.offsetParent)}},_actionSelector:function(c){var b=this,a=this.s.dt,d=j.actions,f=[];e.each(d,function(b,d){d.available(a,c)&&f.push(b)});if(1===f.length&&!1===this.c.alwaysAsk){var h=d[f[0]].execute(a,c);this._update(h,c)}else{var g=this.dom.list.children("ul").empty();f.push("cancel");e.each(f,
|
188 |
+
function(f,h){g.append(e("<li/>").append('<div class="dt-autofill-question">'+d[h].option(a,c)+"<div>").append(e('<div class="dt-autofill-button">').append(e('<button class="'+j.classes.btn+'">'+a.i18n("autoFill.button",">")+"</button>").on("click",function(){var f=d[h].execute(a,c,e(this).closest("li"));b._update(f,c);b.dom.background.remove();b.dom.list.remove()}))))});this.dom.background.appendTo("body");this.dom.list.appendTo("body");this.dom.list.css("margin-top",-1*(this.dom.list.outerHeight()/
|
189 |
+
2))}},_detach:function(){this.dom.attachedTo=null;this.dom.handle.detach()},_drawSelection:function(c){var b=this.s.dt,a=this.s.start,d=e(this.dom.start),f=e(c),h={row:b.rows({page:"current"}).nodes().indexOf(f.parent()[0]),column:f.index()},c=b.column.index("toData",h.column);if(b.cell(f).any()&&-1!==b.columns(this.c.columns).indexes().indexOf(c)){this.s.end=h;var g,b=a.row<h.row?d:f;g=a.row<h.row?f:d;c=a.column<h.column?d:f;d=a.column<h.column?f:d;b=this._getPosition(b).top;c=this._getPosition(c).left;
|
190 |
+
a=this._getPosition(g).top+g.outerHeight()-b;d=this._getPosition(d).left+d.outerWidth()-c;f=this.dom.select;f.top.css({top:b,left:c,width:d});f.left.css({top:b,left:c,height:a});f.bottom.css({top:b+a,left:c,width:d});f.right.css({top:b,left:c+d,height:a})}},_editor:function(c){var b=this.s.dt,a=this.c.editor;if(a){for(var d={},f=[],e=a.fields(),g=0,i=c.length;g<i;g++)for(var j=0,l=c[g].length;j<l;j++){var o=c[g][j],k=b.settings()[0].aoColumns[o.index.column],n=k.editField;if(n===q)for(var k=k.mData,
|
191 |
+
m=0,p=e.length;m<p;m++){var r=a.field(e[m]);if(r.dataSrc()===k){n=r.name();break}}if(!n)throw"Could not automatically determine field data. Please see https://datatables.net/tn/11";d[n]||(d[n]={});k=b.row(o.index.row).id();d[n][k]=o.set;f.push(o.index)}a.bubble(f,!1).multiSet(d).submit()}},_emitEvent:function(c,b){this.s.dt.iterator("table",function(a){e(a.nTable).triggerHandler(c+".dt",b)})},_focusListener:function(){var c=this,b=this.s.dt,a=this.s.namespace,d=null!==this.c.focus?this.c.focus:b.init().keys||
|
192 |
+
b.settings()[0].keytable?"focus":"hover";if("focus"===d)b.on("key-focus.autoFill",function(b,a,d){c._attach(d.node())}).on("key-blur.autoFill",function(){c._detach()});else if("click"===d)e(b.table().body()).on("click"+a,"td, th",function(){c._attach(this)}),e(i.body).on("click"+a,function(a){e(a.target).parents().filter(b.table().body()).length||c._detach()});else e(b.table().body()).on("mouseenter"+a,"td, th",function(){c._attach(this)}).on("mouseleave"+a,function(b){e(b.relatedTarget).hasClass("dt-autofill-handle")||
|
193 |
+
c._detach()})},_focusListenerRemove:function(){var c=this.s.dt;c.off(".autoFill");e(c.table().body()).off(this.s.namespace);e(i.body).off(this.s.namespace)},_getPosition:function(c,b){var a=e(c),d,f,h=0,g=0;b||(b=e(this.s.dt.table().node()).offsetParent());do{f=a.position();d=a.offsetParent();h+=f.top+d.scrollTop();g+=f.left+d.scrollLeft();if("body"===a.get(0).nodeName.toLowerCase())break;a=d}while(d.get(0)!==b.get(0));return{top:h,left:g}},_mousedown:function(c){var b=this,a=this.s.dt;this.dom.start=
|
194 |
+
this.dom.attachedTo;this.s.start={row:a.rows({page:"current"}).nodes().indexOf(e(this.dom.start).parent()[0]),column:e(this.dom.start).index()};e(i.body).on("mousemove.autoFill",function(a){b._mousemove(a)}).on("mouseup.autoFill",function(a){b._mouseup(a)});var d=this.dom.select,a=e(a.table().node()).offsetParent();d.top.appendTo(a);d.left.appendTo(a);d.right.appendTo(a);d.bottom.appendTo(a);this._drawSelection(this.dom.start,c);this.dom.handle.css("display","none");c=this.dom.dtScroll;this.s.scroll=
|
195 |
+
{windowHeight:e(l).height(),windowWidth:e(l).width(),dtTop:c?c.offset().top:null,dtLeft:c?c.offset().left:null,dtHeight:c?c.outerHeight():null,dtWidth:c?c.outerWidth():null}},_mousemove:function(c){var b=c.target.nodeName.toLowerCase();"td"!==b&&"th"!==b||(this._drawSelection(c.target,c),this._shiftScroll(c))},_mouseup:function(){e(i.body).off(".autoFill");var c=this.s.dt,b=this.dom.select;b.top.remove();b.left.remove();b.right.remove();b.bottom.remove();this.dom.handle.css("display","block");var b=
|
196 |
+
this.s.start,a=this.s.end;if(!(b.row===a.row&&b.column===a.column)){for(var d=this._range(b.row,a.row),b=this._range(b.column,a.column),a=[],f=c.settings()[0],h=f.aoColumns,g=0;g<d.length;g++)a.push(e.map(b,function(a){var a=c.cell(":eq("+d[g]+")",a+":visible",{page:"current"}),b=a.data(),e=a.index(),i=h[e.column].editField;i!==q&&(b=f.oApi._fnGetObjectDataFn(i)(c.row(e.row).data()));return{cell:a,data:b,label:a.data(),index:e}}));this._actionSelector(a);clearInterval(this.s.scrollInterval);this.s.scrollInterval=
|
197 |
+
null}},_range:function(c,b){var a=[],d;if(c<=b)for(d=c;d<=b;d++)a.push(d);else for(d=c;d>=b;d--)a.push(d);return a},_shiftScroll:function(c){var b=this,a=this.s.scroll,d=!1,f=c.pageY-i.body.scrollTop,e=c.pageX-i.body.scrollLeft,g,j,k,l;65>f?g=-5:f>a.windowHeight-65&&(g=5);65>e?j=-5:e>a.windowWidth-65&&(j=5);null!==a.dtTop&&c.pageY<a.dtTop+65?k=-5:null!==a.dtTop&&c.pageY>a.dtTop+a.dtHeight-65&&(k=5);null!==a.dtLeft&&c.pageX<a.dtLeft+65?l=-5:null!==a.dtLeft&&c.pageX>a.dtLeft+a.dtWidth-65&&(l=5);g||
|
198 |
+
j||k||l?(a.windowVert=g,a.windowHoriz=j,a.dtVert=k,a.dtHoriz=l,d=!0):this.s.scrollInterval&&(clearInterval(this.s.scrollInterval),this.s.scrollInterval=null);!this.s.scrollInterval&&d&&(this.s.scrollInterval=setInterval(function(){if(a.windowVert)i.body.scrollTop=i.body.scrollTop+a.windowVert;if(a.windowHoriz)i.body.scrollLeft=i.body.scrollLeft+a.windowHoriz;if(a.dtVert||a.dtHoriz){var c=b.dom.dtScroll[0];if(a.dtVert)c.scrollTop=c.scrollTop+a.dtVert;if(a.dtHoriz)c.scrollLeft=c.scrollLeft+a.dtHoriz}},
|
199 |
+
20))},_update:function(c,b){if(!1!==c){var a=this.s.dt,d;this._emitEvent("preAutoFill",[a,b]);this._editor(b);if(null!==this.c.update?this.c.update:!this.c.editor){for(var f=0,e=b.length;f<e;f++)for(var g=0,i=b[f].length;g<i;g++)d=b[f][g],d.cell.data(d.set);a.draw(!1)}this._emitEvent("autoFill",[a,b])}}});j.actions={increment:{available:function(c,b){return e.isNumeric(b[0][0].label)},option:function(c){return c.i18n("autoFill.increment",'Increment / decrement each cell by: <input type="number" value="1">')},
|
200 |
+
execute:function(c,b,a){for(var c=1*b[0][0].data,a=1*e("input",a).val(),d=0,f=b.length;d<f;d++)for(var h=0,g=b[d].length;h<g;h++)b[d][h].set=c,c+=a}},fill:{available:function(){return!0},option:function(c,b){return c.i18n("autoFill.fill","Fill all cells with <i>"+b[0][0].label+"</i>")},execute:function(c,b){for(var a=b[0][0].data,d=0,e=b.length;d<e;d++)for(var h=0,g=b[d].length;h<g;h++)b[d][h].set=a}},fillHorizontal:{available:function(c,b){return 1<b.length&&1<b[0].length},option:function(c){return c.i18n("autoFill.fillHorizontal",
|
201 |
+
"Fill cells horizontally")},execute:function(c,b){for(var a=0,d=b.length;a<d;a++)for(var e=0,h=b[a].length;e<h;e++)b[a][e].set=b[a][0].data}},fillVertical:{available:function(c,b){return 1<b.length&&1<b[0].length},option:function(c){return c.i18n("autoFill.fillVertical","Fill cells vertically")},execute:function(c,b){for(var a=0,d=b.length;a<d;a++)for(var e=0,h=b[a].length;e<h;e++)b[a][e].set=b[0][e].data}},cancel:{available:function(){return!1},option:function(c){return c.i18n("autoFill.cancel",
|
202 |
+
"Cancel")},execute:function(){return!1}}};j.version="2.2.2";j.defaults={alwaysAsk:!1,focus:null,columns:"",enable:!0,update:null,editor:null};j.classes={btn:"btn"};var m=e.fn.dataTable.Api;m.register("autoFill()",function(){return this});m.register("autoFill().enabled()",function(){var c=this.context[0];return c.autoFill?c.autoFill.enabled():!1});m.register("autoFill().enable()",function(c){return this.iterator("table",function(b){b.autoFill&&b.autoFill.enable(c)})});m.register("autoFill().disable()",
|
203 |
+
function(){return this.iterator("table",function(c){c.autoFill&&c.autoFill.disable()})});e(i).on("preInit.dt.autofill",function(c,b){if("dt"===c.namespace){var a=b.oInit.autoFill,d=k.defaults.autoFill;if(a||d)d=e.extend({},a,d),!1!==a&&new j(b,d)}});k.AutoFill=j;return k.AutoFill=j});
|
204 |
+
|
205 |
+
|
206 |
+
/*!
|
207 |
+
Buttons for DataTables 1.5.1
|
208 |
+
©2016-2017 SpryMedia Ltd - datatables.net/license
|
209 |
+
*/
|
210 |
+
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(o){return d(o,window,document)}):"object"===typeof exports?module.exports=function(o,n){o||(o=window);if(!n||!n.fn.dataTable)n=require("datatables.net")(o,n).$;return d(n,o,o.document)}:d(jQuery,window,document)})(function(d,o,n,l){var i=d.fn.dataTable,x=0,y=0,j=i.ext.buttons,m=function(a,b){"undefined"===typeof b&&(b={});!0===b&&(b={});d.isArray(b)&&(b={buttons:b});this.c=d.extend(!0,{},m.defaults,b);
|
211 |
+
b.buttons&&(this.c.buttons=b.buttons);this.s={dt:new i.Api(a),buttons:[],listenKeys:"",namespace:"dtb"+x++};this.dom={container:d("<"+this.c.dom.container.tag+"/>").addClass(this.c.dom.container.className)};this._constructor()};d.extend(m.prototype,{action:function(a,b){var c=this._nodeToButton(a);if(b===l)return c.conf.action;c.conf.action=b;return this},active:function(a,b){var c=this._nodeToButton(a),e=this.c.dom.button.active,c=d(c.node);if(b===l)return c.hasClass(e);c.toggleClass(e,b===l?!0:
|
212 |
+
b);return this},add:function(a,b){var c=this.s.buttons;if("string"===typeof b){for(var e=b.split("-"),c=this.s,d=0,g=e.length-1;d<g;d++)c=c.buttons[1*e[d]];c=c.buttons;b=1*e[e.length-1]}this._expandButton(c,a,!1,b);this._draw();return this},container:function(){return this.dom.container},disable:function(a){a=this._nodeToButton(a);d(a.node).addClass(this.c.dom.button.disabled);return this},destroy:function(){d("body").off("keyup."+this.s.namespace);var a=this.s.buttons.slice(),b,c;b=0;for(c=a.length;b<
|
213 |
+
c;b++)this.remove(a[b].node);this.dom.container.remove();a=this.s.dt.settings()[0];b=0;for(c=a.length;b<c;b++)if(a.inst===this){a.splice(b,1);break}return this},enable:function(a,b){if(!1===b)return this.disable(a);var c=this._nodeToButton(a);d(c.node).removeClass(this.c.dom.button.disabled);return this},name:function(){return this.c.name},node:function(a){a=this._nodeToButton(a);return d(a.node)},processing:function(a,b){var c=this._nodeToButton(a);if(b===l)return d(c.node).hasClass("processing");
|
214 |
+
d(c.node).toggleClass("processing",b);return this},remove:function(a){var b=this._nodeToButton(a),c=this._nodeToHost(a),e=this.s.dt;if(b.buttons.length)for(var h=b.buttons.length-1;0<=h;h--)this.remove(b.buttons[h].node);b.conf.destroy&&b.conf.destroy.call(e.button(a),e,d(a),b.conf);this._removeKey(b.conf);d(b.node).remove();a=d.inArray(b,c);c.splice(a,1);return this},text:function(a,b){var c=this._nodeToButton(a),e=this.c.dom.collection.buttonLiner,e=c.inCollection&&e&&e.tag?e.tag:this.c.dom.buttonLiner.tag,
|
215 |
+
h=this.s.dt,g=d(c.node),f=function(a){return"function"===typeof a?a(h,g,c.conf):a};if(b===l)return f(c.conf.text);c.conf.text=b;e?g.children(e).html(f(b)):g.html(f(b));return this},_constructor:function(){var a=this,b=this.s.dt,c=b.settings()[0],e=this.c.buttons;c._buttons||(c._buttons=[]);c._buttons.push({inst:this,name:this.c.name});for(var c=0,h=e.length;c<h;c++)this.add(e[c]);b.on("destroy",function(){a.destroy()});d("body").on("keyup."+this.s.namespace,function(b){if(!n.activeElement||n.activeElement===
|
216 |
+
n.body){var c=String.fromCharCode(b.keyCode).toLowerCase();a.s.listenKeys.toLowerCase().indexOf(c)!==-1&&a._keypress(c,b)}})},_addKey:function(a){a.key&&(this.s.listenKeys+=d.isPlainObject(a.key)?a.key.key:a.key)},_draw:function(a,b){a||(a=this.dom.container,b=this.s.buttons);a.children().detach();for(var c=0,e=b.length;c<e;c++)a.append(b[c].inserter),a.append(" "),b[c].buttons&&b[c].buttons.length&&this._draw(b[c].collection,b[c].buttons)},_expandButton:function(a,b,c,e){for(var h=this.s.dt,g=0,
|
217 |
+
b=!d.isArray(b)?[b]:b,f=0,q=b.length;f<q;f++){var k=this._resolveExtends(b[f]);if(k)if(d.isArray(k))this._expandButton(a,k,c,e);else{var p=this._buildButton(k,c);if(p){e!==l?(a.splice(e,0,p),e++):a.push(p);if(p.conf.buttons){var u=this.c.dom.collection;p.collection=d("<"+u.tag+"/>").addClass(u.className).attr("role","menu");p.conf._collection=p.collection;this._expandButton(p.buttons,p.conf.buttons,!0,e)}k.init&&k.init.call(h.button(p.node),h,d(p.node),k);g++}}}},_buildButton:function(a,b){var c=
|
218 |
+
this.c.dom.button,e=this.c.dom.buttonLiner,h=this.c.dom.collection,g=this.s.dt,f=function(b){return"function"===typeof b?b(g,k,a):b};b&&h.button&&(c=h.button);b&&h.buttonLiner&&(e=h.buttonLiner);if(a.available&&!a.available(g,a))return!1;var q=function(a,b,c,e){e.action.call(b.button(c),a,b,c,e);d(b.table().node()).triggerHandler("buttons-action.dt",[b.button(c),b,c,e])},k=d("<"+c.tag+"/>").addClass(c.className).attr("tabindex",this.s.dt.settings()[0].iTabIndex).attr("aria-controls",this.s.dt.table().node().id).on("click.dtb",
|
219 |
+
function(b){b.preventDefault();!k.hasClass(c.disabled)&&a.action&&q(b,g,k,a);k.blur()}).on("keyup.dtb",function(b){b.keyCode===13&&!k.hasClass(c.disabled)&&a.action&&q(b,g,k,a)});"a"===c.tag.toLowerCase()&&k.attr("href","#");e.tag?(h=d("<"+e.tag+"/>").html(f(a.text)).addClass(e.className),"a"===e.tag.toLowerCase()&&h.attr("href","#"),k.append(h)):k.html(f(a.text));!1===a.enabled&&k.addClass(c.disabled);a.className&&k.addClass(a.className);a.titleAttr&&k.attr("title",f(a.titleAttr));a.attr&&k.attr(a.attr);
|
220 |
+
a.namespace||(a.namespace=".dt-button-"+y++);e=(e=this.c.dom.buttonContainer)&&e.tag?d("<"+e.tag+"/>").addClass(e.className).append(k):k;this._addKey(a);return{conf:a,node:k.get(0),inserter:e,buttons:[],inCollection:b,collection:null}},_nodeToButton:function(a,b){b||(b=this.s.buttons);for(var c=0,e=b.length;c<e;c++){if(b[c].node===a)return b[c];if(b[c].buttons.length){var d=this._nodeToButton(a,b[c].buttons);if(d)return d}}},_nodeToHost:function(a,b){b||(b=this.s.buttons);for(var c=0,e=b.length;c<
|
221 |
+
e;c++){if(b[c].node===a)return b;if(b[c].buttons.length){var d=this._nodeToHost(a,b[c].buttons);if(d)return d}}},_keypress:function(a,b){if(!b._buttonsHandled){var c=function(e){for(var h=0,g=e.length;h<g;h++){var f=e[h].conf,q=e[h].node;if(f.key)if(f.key===a)b._buttonsHandled=!0,d(q).click();else if(d.isPlainObject(f.key)&&f.key.key===a&&(!f.key.shiftKey||b.shiftKey))if(!f.key.altKey||b.altKey)if(!f.key.ctrlKey||b.ctrlKey)if(!f.key.metaKey||b.metaKey)b._buttonsHandled=!0,d(q).click();e[h].buttons.length&&
|
222 |
+
c(e[h].buttons)}};c(this.s.buttons)}},_removeKey:function(a){if(a.key){var b=d.isPlainObject(a.key)?a.key.key:a.key,a=this.s.listenKeys.split(""),b=d.inArray(b,a);a.splice(b,1);this.s.listenKeys=a.join("")}},_resolveExtends:function(a){for(var b=this.s.dt,c,e,h=function(c){for(var e=0;!d.isPlainObject(c)&&!d.isArray(c);){if(c===l)return;if("function"===typeof c){if(c=c(b,a),!c)return!1}else if("string"===typeof c){if(!j[c])throw"Unknown button type: "+c;c=j[c]}e++;if(30<e)throw"Buttons: Too many iterations";
|
223 |
+
}return d.isArray(c)?c:d.extend({},c)},a=h(a);a&&a.extend;){if(!j[a.extend])throw"Cannot extend unknown button type: "+a.extend;var g=h(j[a.extend]);if(d.isArray(g))return g;if(!g)return!1;c=g.className;a=d.extend({},g,a);c&&a.className!==c&&(a.className=c+" "+a.className);var f=a.postfixButtons;if(f){a.buttons||(a.buttons=[]);c=0;for(e=f.length;c<e;c++)a.buttons.push(f[c]);a.postfixButtons=null}if(f=a.prefixButtons){a.buttons||(a.buttons=[]);c=0;for(e=f.length;c<e;c++)a.buttons.splice(c,0,f[c]);
|
224 |
+
a.prefixButtons=null}a.extend=g.extend}return a}});m.background=function(a,b,c){c===l&&(c=400);a?d("<div/>").addClass(b).css("display","none").appendTo("body").fadeIn(c):d("body > div."+b).fadeOut(c,function(){d(this).removeClass(b).remove()})};m.instanceSelector=function(a,b){if(!a)return d.map(b,function(a){return a.inst});var c=[],e=d.map(b,function(a){return a.name}),h=function(a){if(d.isArray(a))for(var f=0,q=a.length;f<q;f++)h(a[f]);else"string"===typeof a?-1!==a.indexOf(",")?h(a.split(",")):
|
225 |
+
(a=d.inArray(d.trim(a),e),-1!==a&&c.push(b[a].inst)):"number"===typeof a&&c.push(b[a].inst)};h(a);return c};m.buttonSelector=function(a,b){for(var c=[],e=function(a,b,c){for(var d,f,h=0,g=b.length;h<g;h++)if(d=b[h])f=c!==l?c+h:h+"",a.push({node:d.node,name:d.conf.name,idx:f}),d.buttons&&e(a,d.buttons,f+"-")},h=function(a,b){var f,g,i=[];e(i,b.s.buttons);f=d.map(i,function(a){return a.node});if(d.isArray(a)||a instanceof d){f=0;for(g=a.length;f<g;f++)h(a[f],b)}else if(null===a||a===l||"*"===a){f=0;
|
226 |
+
for(g=i.length;f<g;f++)c.push({inst:b,node:i[f].node})}else if("number"===typeof a)c.push({inst:b,node:b.s.buttons[a].node});else if("string"===typeof a)if(-1!==a.indexOf(",")){i=a.split(",");f=0;for(g=i.length;f<g;f++)h(d.trim(i[f]),b)}else if(a.match(/^\d+(\-\d+)*$/))f=d.map(i,function(a){return a.idx}),c.push({inst:b,node:i[d.inArray(a,f)].node});else if(-1!==a.indexOf(":name")){var j=a.replace(":name","");f=0;for(g=i.length;f<g;f++)i[f].name===j&&c.push({inst:b,node:i[f].node})}else d(f).filter(a).each(function(){c.push({inst:b,
|
227 |
+
node:this})});else"object"===typeof a&&a.nodeName&&(i=d.inArray(a,f),-1!==i&&c.push({inst:b,node:f[i]}))},g=0,f=a.length;g<f;g++)h(b,a[g]);return c};m.defaults={buttons:["copy","excel","csv","pdf","print"],name:"main",tabIndex:0,dom:{container:{tag:"div",className:"dt-buttons"},collection:{tag:"div",className:"dt-button-collection"},button:{tag:"button",className:"dt-button",active:"active",disabled:"disabled"},buttonLiner:{tag:"span",className:""}}};m.version="1.5.1";d.extend(j,{collection:{text:function(a){return a.i18n("buttons.collection",
|
228 |
+
"Collection")},className:"buttons-collection",action:function(a,b,c,e){var h=d(c).parents("div.dt-button-collection"),a=c.position(),g=d(b.table().container()),f=!1,i=c;h.length&&(f=d(".dt-button-collection").position(),i=h,d("body").trigger("click.dtb-collection"));e._collection.addClass(e.collectionLayout).css("display","none").insertAfter(i).fadeIn(e.fade);h=e._collection.css("position");f&&"absolute"===h?e._collection.css({top:f.top,left:f.left}):"absolute"===h?(e._collection.css({top:a.top+c.outerHeight(),
|
229 |
+
left:a.left}),f=g.offset().top+g.height(),c=a.top+c.outerHeight()+e._collection.outerHeight()-f,f=a.top-e._collection.outerHeight(),f=g.offset().top-f,c>f&&e._collection.css("top",a.top-e._collection.outerHeight()-5),c=a.left+e._collection.outerWidth(),g=g.offset().left+g.width(),c>g&&e._collection.css("left",a.left-(c-g))):(a=e._collection.height()/2,a>d(o).height()/2&&(a=d(o).height()/2),e._collection.css("marginTop",-1*a));e.background&&m.background(!0,e.backgroundClassName,e.fade);setTimeout(function(){d("div.dt-button-background").on("click.dtb-collection",
|
230 |
+
function(){});d("body").on("click.dtb-collection",function(a){var c=d.fn.addBack?"addBack":"andSelf";if(!d(a.target).parents()[c]().filter(e._collection).length){e._collection.fadeOut(e.fade,function(){e._collection.detach()});d("div.dt-button-background").off("click.dtb-collection");m.background(false,e.backgroundClassName,e.fade);d("body").off("click.dtb-collection");b.off("buttons-action.b-internal")}})},10);if(e.autoClose)b.on("buttons-action.b-internal",function(){d("div.dt-button-background").click()})},
|
231 |
+
background:!0,collectionLayout:"",backgroundClassName:"dt-button-background",autoClose:!1,fade:400,attr:{"aria-haspopup":!0}},copy:function(a,b){if(j.copyHtml5)return"copyHtml5";if(j.copyFlash&&j.copyFlash.available(a,b))return"copyFlash"},csv:function(a,b){if(j.csvHtml5&&j.csvHtml5.available(a,b))return"csvHtml5";if(j.csvFlash&&j.csvFlash.available(a,b))return"csvFlash"},excel:function(a,b){if(j.excelHtml5&&j.excelHtml5.available(a,b))return"excelHtml5";if(j.excelFlash&&j.excelFlash.available(a,
|
232 |
+
b))return"excelFlash"},pdf:function(a,b){if(j.pdfHtml5&&j.pdfHtml5.available(a,b))return"pdfHtml5";if(j.pdfFlash&&j.pdfFlash.available(a,b))return"pdfFlash"},pageLength:function(a){var a=a.settings()[0].aLengthMenu,b=d.isArray(a[0])?a[0]:a,c=d.isArray(a[0])?a[1]:a,e=function(a){return a.i18n("buttons.pageLength",{"-1":"Show all rows",_:"Show %d rows"},a.page.len())};return{extend:"collection",text:e,className:"buttons-page-length",autoClose:!0,buttons:d.map(b,function(a,b){return{text:c[b],className:"button-page-length",
|
233 |
+
action:function(b,c){c.page.len(a).draw()},init:function(b,c,d){var e=this,c=function(){e.active(b.page.len()===a)};b.on("length.dt"+d.namespace,c);c()},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}),init:function(a,b,c){var d=this;a.on("length.dt"+c.namespace,function(){d.text(e(a))})},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}});i.Api.register("buttons()",function(a,b){b===l&&(b=a,a=l);this.selector.buttonGroup=a;var c=this.iterator(!0,"table",function(c){if(c._buttons)return m.buttonSelector(m.instanceSelector(a,
|
234 |
+
c._buttons),b)},!0);c._groupSelector=a;return c});i.Api.register("button()",function(a,b){var c=this.buttons(a,b);1<c.length&&c.splice(1,c.length);return c});i.Api.registerPlural("buttons().active()","button().active()",function(a){return a===l?this.map(function(a){return a.inst.active(a.node)}):this.each(function(b){b.inst.active(b.node,a)})});i.Api.registerPlural("buttons().action()","button().action()",function(a){return a===l?this.map(function(a){return a.inst.action(a.node)}):this.each(function(b){b.inst.action(b.node,
|
235 |
+
a)})});i.Api.register(["buttons().enable()","button().enable()"],function(a){return this.each(function(b){b.inst.enable(b.node,a)})});i.Api.register(["buttons().disable()","button().disable()"],function(){return this.each(function(a){a.inst.disable(a.node)})});i.Api.registerPlural("buttons().nodes()","button().node()",function(){var a=d();d(this.each(function(b){a=a.add(b.inst.node(b.node))}));return a});i.Api.registerPlural("buttons().processing()","button().processing()",function(a){return a===
|
236 |
+
l?this.map(function(a){return a.inst.processing(a.node)}):this.each(function(b){b.inst.processing(b.node,a)})});i.Api.registerPlural("buttons().text()","button().text()",function(a){return a===l?this.map(function(a){return a.inst.text(a.node)}):this.each(function(b){b.inst.text(b.node,a)})});i.Api.registerPlural("buttons().trigger()","button().trigger()",function(){return this.each(function(a){a.inst.node(a.node).trigger("click")})});i.Api.registerPlural("buttons().containers()","buttons().container()",
|
237 |
+
function(){var a=d(),b=this._groupSelector;this.iterator(!0,"table",function(c){if(c._buttons)for(var c=m.instanceSelector(b,c._buttons),d=0,h=c.length;d<h;d++)a=a.add(c[d].container())});return a});i.Api.register("button().add()",function(a,b){var c=this.context;c.length&&(c=m.instanceSelector(this._groupSelector,c[0]._buttons),c.length&&c[0].add(b,a));return this.button(this._groupSelector,a)});i.Api.register("buttons().destroy()",function(){this.pluck("inst").unique().each(function(a){a.destroy()});
|
238 |
+
return this});i.Api.registerPlural("buttons().remove()","buttons().remove()",function(){this.each(function(a){a.inst.remove(a.node)});return this});var r;i.Api.register("buttons.info()",function(a,b,c){var e=this;if(!1===a)return d("#datatables_buttons_info").fadeOut(function(){d(this).remove()}),clearTimeout(r),r=null,this;r&&clearTimeout(r);d("#datatables_buttons_info").length&&d("#datatables_buttons_info").remove();d('<div id="datatables_buttons_info" class="dt-button-info"/>').html(a?"<h2>"+a+
|
239 |
+
"</h2>":"").append(d("<div/>")["string"===typeof b?"html":"append"](b)).css("display","none").appendTo("body").fadeIn();c!==l&&0!==c&&(r=setTimeout(function(){e.buttons.info(!1)},c));return this});i.Api.register("buttons.exportData()",function(a){if(this.context.length){var b=new i.Api(this.context[0]),c=d.extend(!0,{},{rows:null,columns:"",modifier:{search:"applied",order:"applied"},orthogonal:"display",stripHtml:!0,stripNewlines:!0,decodeEntities:!0,trim:!0,format:{header:function(a){return e(a)},
|
240 |
+
footer:function(a){return e(a)},body:function(a){return e(a)}}},a),e=function(a){if("string"!==typeof a)return a;a=a.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,"");c.stripHtml&&(a=a.replace(/<[^>]*>/g,""));c.trim&&(a=a.replace(/^\s+|\s+$/g,""));c.stripNewlines&&(a=a.replace(/\n/g," "));c.decodeEntities&&(v.innerHTML=a,a=v.value);return a},a=b.columns(c.columns).indexes().map(function(a){var d=b.column(a).header();return c.format.header(d.innerHTML,a,d)}).toArray(),h=b.table().footer()?
|
241 |
+
b.columns(c.columns).indexes().map(function(a){var d=b.column(a).footer();return c.format.footer(d?d.innerHTML:"",a,d)}).toArray():null,g=d.extend({},c.modifier);b.select&&"function"===typeof b.select.info&&g.selected===l&&b.rows(c.rows,d.extend({selected:!0},g)).any()&&d.extend(g,{selected:!0});for(var g=b.rows(c.rows,g).indexes().toArray(),f=b.cells(g,c.columns),g=f.render(c.orthogonal).toArray(),f=f.nodes().toArray(),j=a.length,k=0<j?g.length/j:0,m=[k],o=0,n=0;n<k;n++){for(var r=[j],s=0;s<j;s++)r[s]=
|
242 |
+
c.format.body(g[o],n,s,f[o]),o++;m[n]=r}return{header:a,footer:h,body:m}}});i.Api.register("buttons.exportInfo()",function(a){a||(a={});var b;var c=a;b="*"===c.filename&&"*"!==c.title&&c.title!==l&&null!==c.title&&""!==c.title?c.title:c.filename;"function"===typeof b&&(b=b());b===l||null===b?b=null:(-1!==b.indexOf("*")&&(b=d.trim(b.replace("*",d("head > title").text()))),b=b.replace(/[^a-zA-Z0-9_\u00A1-\uFFFF\.,\-_ !\(\)]/g,""),(c=t(c.extension))||(c=""),b+=c);c=t(a.title);c=null===c?null:-1!==c.indexOf("*")?
|
243 |
+
c.replace("*",d("head > title").text()||"Exported data"):c;return{filename:b,title:c,messageTop:w(this,a.message||a.messageTop,"top"),messageBottom:w(this,a.messageBottom,"bottom")}});var t=function(a){return null===a||a===l?null:"function"===typeof a?a():a},w=function(a,b,c){b=t(b);if(null===b)return null;a=d("caption",a.table().container()).eq(0);return"*"===b?a.css("caption-side")!==c?null:a.length?a.text():"":b},v=d("<textarea/>")[0];d.fn.dataTable.Buttons=m;d.fn.DataTable.Buttons=m;d(n).on("init.dt plugin-init.dt",
|
244 |
+
function(a,b){if("dt"===a.namespace){var c=b.oInit.buttons||i.defaults.buttons;c&&!b._buttons&&(new m(b,c)).container()}});i.ext.feature.push({fnInit:function(a){var a=new i.Api(a),b=a.init().buttons||i.defaults.buttons;return(new m(a,b)).container()},cFeature:"B"});return m});
|
245 |
+
|
246 |
+
|
247 |
+
/*!
|
248 |
+
ColReorder 1.4.1
|
249 |
+
©2010-2017 SpryMedia Ltd - datatables.net/license
|
250 |
+
*/
|
251 |
+
(function(f){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(o){return f(o,window,document)}):"object"===typeof exports?module.exports=function(o,l){o||(o=window);if(!l||!l.fn.dataTable)l=require("datatables.net")(o,l).$;return f(l,o,o.document)}:f(jQuery,window,document)})(function(f,o,l,r){function q(a){for(var b=[],c=0,e=a.length;c<e;c++)b[a[c]]=c;return b}function p(a,b,c){b=a.splice(b,1)[0];a.splice(c,0,b)}function s(a,b,c){for(var e=[],f=0,d=a.childNodes.length;f<
|
252 |
+
d;f++)1==a.childNodes[f].nodeType&&e.push(a.childNodes[f]);b=e[b];null!==c?a.insertBefore(b,e[c]):a.appendChild(b)}var t=f.fn.dataTable;f.fn.dataTableExt.oApi.fnColReorder=function(a,b,c,e,g){var d,h,j,m,i,l=a.aoColumns.length,k;i=function(a,b,d){if(a[b]&&"function"!==typeof a[b]){var c=a[b].split("."),e=c.shift();isNaN(1*e)||(a[b]=d[1*e]+"."+c.join("."))}};if(b!=c)if(0>b||b>=l)this.oApi._fnLog(a,1,"ColReorder 'from' index is out of bounds: "+b);else if(0>c||c>=l)this.oApi._fnLog(a,1,"ColReorder 'to' index is out of bounds: "+
|
253 |
+
c);else{j=[];d=0;for(h=l;d<h;d++)j[d]=d;p(j,b,c);var n=q(j);d=0;for(h=a.aaSorting.length;d<h;d++)a.aaSorting[d][0]=n[a.aaSorting[d][0]];if(null!==a.aaSortingFixed){d=0;for(h=a.aaSortingFixed.length;d<h;d++)a.aaSortingFixed[d][0]=n[a.aaSortingFixed[d][0]]}d=0;for(h=l;d<h;d++){k=a.aoColumns[d];j=0;for(m=k.aDataSort.length;j<m;j++)k.aDataSort[j]=n[k.aDataSort[j]];k.idx=n[k.idx]}f.each(a.aLastSort,function(b,c){a.aLastSort[b].src=n[c.src]});d=0;for(h=l;d<h;d++)k=a.aoColumns[d],"number"==typeof k.mData?
|
254 |
+
k.mData=n[k.mData]:f.isPlainObject(k.mData)&&(i(k.mData,"_",n),i(k.mData,"filter",n),i(k.mData,"sort",n),i(k.mData,"type",n));if(a.aoColumns[b].bVisible){i=this.oApi._fnColumnIndexToVisible(a,b);m=null;for(d=c<b?c:c+1;null===m&&d<l;)m=this.oApi._fnColumnIndexToVisible(a,d),d++;j=a.nTHead.getElementsByTagName("tr");d=0;for(h=j.length;d<h;d++)s(j[d],i,m);if(null!==a.nTFoot){j=a.nTFoot.getElementsByTagName("tr");d=0;for(h=j.length;d<h;d++)s(j[d],i,m)}d=0;for(h=a.aoData.length;d<h;d++)null!==a.aoData[d].nTr&&
|
255 |
+
s(a.aoData[d].nTr,i,m)}p(a.aoColumns,b,c);d=0;for(h=l;d<h;d++)a.oApi._fnColumnOptions(a,d,{});p(a.aoPreSearchCols,b,c);d=0;for(h=a.aoData.length;d<h;d++){m=a.aoData[d];if(k=m.anCells){p(k,b,c);j=0;for(i=k.length;j<i;j++)k[j]&&k[j]._DT_CellIndex&&(k[j]._DT_CellIndex.column=j)}"dom"!==m.src&&f.isArray(m._aData)&&p(m._aData,b,c)}d=0;for(h=a.aoHeader.length;d<h;d++)p(a.aoHeader[d],b,c);if(null!==a.aoFooter){d=0;for(h=a.aoFooter.length;d<h;d++)p(a.aoFooter[d],b,c)}(g||g===r)&&f.fn.dataTable.Api(a).rows().invalidate();
|
256 |
+
d=0;for(h=l;d<h;d++)f(a.aoColumns[d].nTh).off("click.DT"),this.oApi._fnSortAttachListener(a,a.aoColumns[d].nTh,d);f(a.oInstance).trigger("column-reorder.dt",[a,{from:b,to:c,mapping:n,drop:e,iFrom:b,iTo:c,aiInvertMapping:n}])}};var i=function(a,b){var c=(new f.fn.dataTable.Api(a)).settings()[0];if(c._colReorder)return c._colReorder;!0===b&&(b={});var e=f.fn.dataTable.camelToHungarian;e&&(e(i.defaults,i.defaults,!0),e(i.defaults,b||{}));this.s={dt:null,init:f.extend(!0,{},i.defaults,b),fixed:0,fixedRight:0,
|
257 |
+
reorderCallback:null,mouse:{startX:-1,startY:-1,offsetX:-1,offsetY:-1,target:-1,targetIndex:-1,fromIndex:-1},aoTargets:[]};this.dom={drag:null,pointer:null};this.s.dt=c;this.s.dt._colReorder=this;this._fnConstruct();return this};f.extend(i.prototype,{fnReset:function(){this._fnOrderColumns(this.fnOrder());return this},fnGetCurrentOrder:function(){return this.fnOrder()},fnOrder:function(a,b){var c=[],e,g,d=this.s.dt.aoColumns;if(a===r){e=0;for(g=d.length;e<g;e++)c.push(d[e]._ColReorder_iOrigCol);return c}if(b){d=
|
258 |
+
this.fnOrder();e=0;for(g=a.length;e<g;e++)c.push(f.inArray(a[e],d));a=c}this._fnOrderColumns(q(a));return this},fnTranspose:function(a,b){b||(b="toCurrent");var c=this.fnOrder(),e=this.s.dt.aoColumns;return"toCurrent"===b?!f.isArray(a)?f.inArray(a,c):f.map(a,function(a){return f.inArray(a,c)}):!f.isArray(a)?e[a]._ColReorder_iOrigCol:f.map(a,function(a){return e[a]._ColReorder_iOrigCol})},_fnConstruct:function(){var a=this,b=this.s.dt.aoColumns.length,c=this.s.dt.nTable,e;this.s.init.iFixedColumns&&
|
259 |
+
(this.s.fixed=this.s.init.iFixedColumns);this.s.init.iFixedColumnsLeft&&(this.s.fixed=this.s.init.iFixedColumnsLeft);this.s.fixedRight=this.s.init.iFixedColumnsRight?this.s.init.iFixedColumnsRight:0;this.s.init.fnReorderCallback&&(this.s.reorderCallback=this.s.init.fnReorderCallback);for(e=0;e<b;e++)e>this.s.fixed-1&&e<b-this.s.fixedRight&&this._fnMouseListener(e,this.s.dt.aoColumns[e].nTh),this.s.dt.aoColumns[e]._ColReorder_iOrigCol=e;this.s.dt.oApi._fnCallbackReg(this.s.dt,"aoStateSaveParams",function(b,
|
260 |
+
c){a._fnStateSave.call(a,c)},"ColReorder_State");var g=null;this.s.init.aiOrder&&(g=this.s.init.aiOrder.slice());this.s.dt.oLoadedState&&("undefined"!=typeof this.s.dt.oLoadedState.ColReorder&&this.s.dt.oLoadedState.ColReorder.length==this.s.dt.aoColumns.length)&&(g=this.s.dt.oLoadedState.ColReorder);if(g)if(a.s.dt._bInitComplete)b=q(g),a._fnOrderColumns.call(a,b);else{var d=!1;f(c).on("draw.dt.colReorder",function(){if(!a.s.dt._bInitComplete&&!d){d=true;var b=q(g);a._fnOrderColumns.call(a,b)}})}else this._fnSetColumnIndexes();
|
261 |
+
f(c).on("destroy.dt.colReorder",function(){f(c).off("destroy.dt.colReorder draw.dt.colReorder");f(a.s.dt.nTHead).find("*").off(".ColReorder");f.each(a.s.dt.aoColumns,function(a,b){f(b.nTh).removeAttr("data-column-index")});a.s.dt._colReorder=null;a.s=null})},_fnOrderColumns:function(a){var b=!1;if(a.length!=this.s.dt.aoColumns.length)this.s.dt.oInstance.oApi._fnLog(this.s.dt,1,"ColReorder - array reorder does not match known number of columns. Skipping.");else{for(var c=0,e=a.length;c<e;c++){var g=
|
262 |
+
f.inArray(c,a);c!=g&&(p(a,g,c),this.s.dt.oInstance.fnColReorder(g,c,!0,!1),b=!0)}f.fn.dataTable.Api(this.s.dt).rows().invalidate();this._fnSetColumnIndexes();b&&((""!==this.s.dt.oScroll.sX||""!==this.s.dt.oScroll.sY)&&this.s.dt.oInstance.fnAdjustColumnSizing(!1),this.s.dt.oInstance.oApi._fnSaveState(this.s.dt),null!==this.s.reorderCallback&&this.s.reorderCallback.call(this))}},_fnStateSave:function(a){var b,c,e,g=this.s.dt.aoColumns;a.ColReorder=[];if(a.aaSorting){for(b=0;b<a.aaSorting.length;b++)a.aaSorting[b][0]=
|
263 |
+
g[a.aaSorting[b][0]]._ColReorder_iOrigCol;var d=f.extend(!0,[],a.aoSearchCols);b=0;for(c=g.length;b<c;b++)e=g[b]._ColReorder_iOrigCol,a.aoSearchCols[e]=d[b],a.abVisCols[e]=g[b].bVisible,a.ColReorder.push(e)}else if(a.order){for(b=0;b<a.order.length;b++)a.order[b][0]=g[a.order[b][0]]._ColReorder_iOrigCol;d=f.extend(!0,[],a.columns);b=0;for(c=g.length;b<c;b++)e=g[b]._ColReorder_iOrigCol,a.columns[e]=d[b],a.ColReorder.push(e)}},_fnMouseListener:function(a,b){var c=this;f(b).on("mousedown.ColReorder",
|
264 |
+
function(a){c._fnMouseDown.call(c,a,b)}).on("touchstart.ColReorder",function(a){c._fnMouseDown.call(c,a,b)})},_fnMouseDown:function(a,b){var c=this,e=f(a.target).closest("th, td").offset(),g=parseInt(f(b).attr("data-column-index"),10);g!==r&&(this.s.mouse.startX=this._fnCursorPosition(a,"pageX"),this.s.mouse.startY=this._fnCursorPosition(a,"pageY"),this.s.mouse.offsetX=this._fnCursorPosition(a,"pageX")-e.left,this.s.mouse.offsetY=this._fnCursorPosition(a,"pageY")-e.top,this.s.mouse.target=this.s.dt.aoColumns[g].nTh,
|
265 |
+
this.s.mouse.targetIndex=g,this.s.mouse.fromIndex=g,this._fnRegions(),f(l).on("mousemove.ColReorder touchmove.ColReorder",function(a){c._fnMouseMove.call(c,a)}).on("mouseup.ColReorder touchend.ColReorder",function(a){c._fnMouseUp.call(c,a)}))},_fnMouseMove:function(a){if(null===this.dom.drag){if(5>Math.pow(Math.pow(this._fnCursorPosition(a,"pageX")-this.s.mouse.startX,2)+Math.pow(this._fnCursorPosition(a,"pageY")-this.s.mouse.startY,2),0.5))return;this._fnCreateDragNode()}this.dom.drag.css({left:this._fnCursorPosition(a,
|
266 |
+
"pageX")-this.s.mouse.offsetX,top:this._fnCursorPosition(a,"pageY")-this.s.mouse.offsetY});for(var b=!1,c=this.s.mouse.toIndex,e=1,f=this.s.aoTargets.length;e<f;e++)if(this._fnCursorPosition(a,"pageX")<this.s.aoTargets[e-1].x+(this.s.aoTargets[e].x-this.s.aoTargets[e-1].x)/2){this.dom.pointer.css("left",this.s.aoTargets[e-1].x);this.s.mouse.toIndex=this.s.aoTargets[e-1].to;b=!0;break}b||(this.dom.pointer.css("left",this.s.aoTargets[this.s.aoTargets.length-1].x),this.s.mouse.toIndex=this.s.aoTargets[this.s.aoTargets.length-
|
267 |
+
1].to);this.s.init.bRealtime&&c!==this.s.mouse.toIndex&&(this.s.dt.oInstance.fnColReorder(this.s.mouse.fromIndex,this.s.mouse.toIndex,!1),this.s.mouse.fromIndex=this.s.mouse.toIndex,this._fnRegions())},_fnMouseUp:function(){f(l).off(".ColReorder");null!==this.dom.drag&&(this.dom.drag.remove(),this.dom.pointer.remove(),this.dom.drag=null,this.dom.pointer=null,this.s.dt.oInstance.fnColReorder(this.s.mouse.fromIndex,this.s.mouse.toIndex,!0),this._fnSetColumnIndexes(),(""!==this.s.dt.oScroll.sX||""!==
|
268 |
+
this.s.dt.oScroll.sY)&&this.s.dt.oInstance.fnAdjustColumnSizing(!1),this.s.dt.oInstance.oApi._fnSaveState(this.s.dt),null!==this.s.reorderCallback&&this.s.reorderCallback.call(this))},_fnRegions:function(){var a=this.s.dt.aoColumns;this.s.aoTargets.splice(0,this.s.aoTargets.length);this.s.aoTargets.push({x:f(this.s.dt.nTable).offset().left,to:0});for(var b=0,c=this.s.aoTargets[0].x,e=0,g=a.length;e<g;e++)e!=this.s.mouse.fromIndex&&b++,a[e].bVisible&&"none"!==a[e].nTh.style.display&&(c+=f(a[e].nTh).outerWidth(),
|
269 |
+
this.s.aoTargets.push({x:c,to:b}));0!==this.s.fixedRight&&this.s.aoTargets.splice(this.s.aoTargets.length-this.s.fixedRight);0!==this.s.fixed&&this.s.aoTargets.splice(0,this.s.fixed)},_fnCreateDragNode:function(){var a=""!==this.s.dt.oScroll.sX||""!==this.s.dt.oScroll.sY,b=this.s.dt.aoColumns[this.s.mouse.targetIndex].nTh,c=b.parentNode,e=c.parentNode,g=e.parentNode,d=f(b).clone();this.dom.drag=f(g.cloneNode(!1)).addClass("DTCR_clonedTable").append(f(e.cloneNode(!1)).append(f(c.cloneNode(!1)).append(d[0]))).css({position:"absolute",
|
270 |
+
top:0,left:0,width:f(b).outerWidth(),height:f(b).outerHeight()}).appendTo("body");this.dom.pointer=f("<div></div>").addClass("DTCR_pointer").css({position:"absolute",top:a?f("div.dataTables_scroll",this.s.dt.nTableWrapper).offset().top:f(this.s.dt.nTable).offset().top,height:a?f("div.dataTables_scroll",this.s.dt.nTableWrapper).height():f(this.s.dt.nTable).height()}).appendTo("body")},_fnSetColumnIndexes:function(){f.each(this.s.dt.aoColumns,function(a,b){f(b.nTh).attr("data-column-index",a)})},_fnCursorPosition:function(a,
|
271 |
+
b){return-1!==a.type.indexOf("touch")?a.originalEvent.touches[0][b]:a[b]}});i.defaults={aiOrder:null,bRealtime:!0,iFixedColumnsLeft:0,iFixedColumnsRight:0,fnReorderCallback:null};i.version="1.4.1";f.fn.dataTable.ColReorder=i;f.fn.DataTable.ColReorder=i;"function"==typeof f.fn.dataTable&&"function"==typeof f.fn.dataTableExt.fnVersionCheck&&f.fn.dataTableExt.fnVersionCheck("1.10.8")?f.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var b=a.oInstance;a._colReorder?b.oApi._fnLog(a,1,"ColReorder attempted to initialise twice. Ignoring second"):
|
272 |
+
(b=a.oInit,new i(a,b.colReorder||b.oColReorder||{}));return null},cFeature:"R",sFeature:"ColReorder"}):alert("Warning: ColReorder requires DataTables 1.10.8 or greater - www.datatables.net/download");f(l).on("preInit.dt.colReorder",function(a,b){if("dt"===a.namespace){var c=b.oInit.colReorder,e=t.defaults.colReorder;if(c||e)e=f.extend({},c,e),!1!==c&&new i(b,e)}});f.fn.dataTable.Api.register("colReorder.reset()",function(){return this.iterator("table",function(a){a._colReorder.fnReset()})});f.fn.dataTable.Api.register("colReorder.order()",
|
273 |
+
function(a,b){return a?this.iterator("table",function(c){c._colReorder.fnOrder(a,b)}):this.context.length?this.context[0]._colReorder.fnOrder():null});f.fn.dataTable.Api.register("colReorder.transpose()",function(a,b){return this.context.length&&this.context[0]._colReorder?this.context[0]._colReorder.fnTranspose(a,b):a});f.fn.dataTable.Api.register("colReorder.move()",function(a,b,c,e){this.context.length&&this.context[0]._colReorder.s.dt.oInstance.fnColReorder(a,b,c,e);return this});return i});
|
274 |
+
|
275 |
+
|
276 |
+
/*!
|
277 |
+
FixedColumns 3.2.4
|
278 |
+
©2010-2017 SpryMedia Ltd - datatables.net/license
|
279 |
+
*/
|
280 |
+
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(p){return d(p,window,document)}):"object"===typeof exports?module.exports=function(p,r){p||(p=window);if(!r||!r.fn.dataTable)r=require("datatables.net")(p,r).$;return d(r,p,p.document)}:d(jQuery,window,document)})(function(d,p,r,t){var s=d.fn.dataTable,u,m=function(a,b){var c=this;if(this instanceof m){if(b===t||!0===b)b={};var e=d.fn.dataTable.camelToHungarian;e&&(e(m.defaults,m.defaults,!0),e(m.defaults,
|
281 |
+
b));e=(new d.fn.dataTable.Api(a)).settings()[0];this.s={dt:e,iTableColumns:e.aoColumns.length,aiOuterWidths:[],aiInnerWidths:[],rtl:"rtl"===d(e.nTable).css("direction")};this.dom={scroller:null,header:null,body:null,footer:null,grid:{wrapper:null,dt:null,left:{wrapper:null,head:null,body:null,foot:null},right:{wrapper:null,head:null,body:null,foot:null}},clone:{left:{header:null,body:null,footer:null},right:{header:null,body:null,footer:null}}};if(e._oFixedColumns)throw"FixedColumns already initialised on this table";
|
282 |
+
e._oFixedColumns=this;e._bInitComplete?this._fnConstruct(b):e.oApi._fnCallbackReg(e,"aoInitComplete",function(){c._fnConstruct(b)},"FixedColumns")}else alert("FixedColumns warning: FixedColumns must be initialised with the 'new' keyword.")};d.extend(m.prototype,{fnUpdate:function(){this._fnDraw(!0)},fnRedrawLayout:function(){this._fnColCalc();this._fnGridLayout();this.fnUpdate()},fnRecalculateHeight:function(a){delete a._DTTC_iHeight;a.style.height="auto"},fnSetRowHeight:function(a,b){a.style.height=
|
283 |
+
b+"px"},fnGetPosition:function(a){var b=this.s.dt.oInstance;if(d(a).parents(".DTFC_Cloned").length){if("tr"===a.nodeName.toLowerCase())return a=d(a).index(),b.fnGetPosition(d("tr",this.s.dt.nTBody)[a]);var c=d(a).index(),a=d(a.parentNode).index();return[b.fnGetPosition(d("tr",this.s.dt.nTBody)[a]),c,b.oApi._fnVisibleToColumnIndex(this.s.dt,c)]}return b.fnGetPosition(a)},_fnConstruct:function(a){var b=this;if("function"!=typeof this.s.dt.oInstance.fnVersionCheck||!0!==this.s.dt.oInstance.fnVersionCheck("1.8.0"))alert("FixedColumns "+
|
284 |
+
m.VERSION+" required DataTables 1.8.0 or later. Please upgrade your DataTables installation");else if(""===this.s.dt.oScroll.sX)this.s.dt.oInstance.oApi._fnLog(this.s.dt,1,"FixedColumns is not needed (no x-scrolling in DataTables enabled), so no action will be taken. Use 'FixedHeader' for column fixing when scrolling is not enabled");else{this.s=d.extend(!0,this.s,m.defaults,a);a=this.s.dt.oClasses;this.dom.grid.dt=d(this.s.dt.nTable).parents("div."+a.sScrollWrapper)[0];this.dom.scroller=d("div."+
|
285 |
+
a.sScrollBody,this.dom.grid.dt)[0];this._fnColCalc();this._fnGridSetup();var c,e=!1;d(this.s.dt.nTableWrapper).on("mousedown.DTFC",function(a){0===a.button&&(e=!0,d(r).one("mouseup",function(){e=!1}))});d(this.dom.scroller).on("mouseover.DTFC touchstart.DTFC",function(){e||(c="main")}).on("scroll.DTFC",function(a){!c&&a.originalEvent&&(c="main");if("main"===c&&(0<b.s.iLeftColumns&&(b.dom.grid.left.liner.scrollTop=b.dom.scroller.scrollTop),0<b.s.iRightColumns))b.dom.grid.right.liner.scrollTop=b.dom.scroller.scrollTop});
|
286 |
+
var f="onwheel"in r.createElement("div")?"wheel.DTFC":"mousewheel.DTFC";if(0<b.s.iLeftColumns)d(b.dom.grid.left.liner).on("mouseover.DTFC touchstart.DTFC",function(){e||(c="left")}).on("scroll.DTFC",function(a){!c&&a.originalEvent&&(c="left");"left"===c&&(b.dom.scroller.scrollTop=b.dom.grid.left.liner.scrollTop,0<b.s.iRightColumns&&(b.dom.grid.right.liner.scrollTop=b.dom.grid.left.liner.scrollTop))}).on(f,function(a){b.dom.scroller.scrollLeft-="wheel"===a.type?-a.originalEvent.deltaX:a.originalEvent.wheelDeltaX});
|
287 |
+
if(0<b.s.iRightColumns)d(b.dom.grid.right.liner).on("mouseover.DTFC touchstart.DTFC",function(){e||(c="right")}).on("scroll.DTFC",function(a){!c&&a.originalEvent&&(c="right");"right"===c&&(b.dom.scroller.scrollTop=b.dom.grid.right.liner.scrollTop,0<b.s.iLeftColumns&&(b.dom.grid.left.liner.scrollTop=b.dom.grid.right.liner.scrollTop))}).on(f,function(a){b.dom.scroller.scrollLeft-="wheel"===a.type?-a.originalEvent.deltaX:a.originalEvent.wheelDeltaX});d(p).on("resize.DTFC",function(){b._fnGridLayout.call(b)});
|
288 |
+
var g=!0,h=d(this.s.dt.nTable);h.on("draw.dt.DTFC",function(){b._fnColCalc();b._fnDraw.call(b,g);g=!1}).on("column-sizing.dt.DTFC",function(){b._fnColCalc();b._fnGridLayout(b)}).on("column-visibility.dt.DTFC",function(a,c,d,e,f){if(f===t||f)b._fnColCalc(),b._fnGridLayout(b),b._fnDraw(!0)}).on("select.dt.DTFC deselect.dt.DTFC",function(a){"dt"===a.namespace&&b._fnDraw(!1)}).on("destroy.dt.DTFC",function(){h.off(".DTFC");d(b.dom.scroller).off(".DTFC");d(p).off(".DTFC");d(b.s.dt.nTableWrapper).off(".DTFC");
|
289 |
+
d(b.dom.grid.left.liner).off(".DTFC "+f);d(b.dom.grid.left.wrapper).remove();d(b.dom.grid.right.liner).off(".DTFC "+f);d(b.dom.grid.right.wrapper).remove()});this._fnGridLayout();this.s.dt.oInstance.fnDraw(!1)}},_fnColCalc:function(){var a=this,b=0,c=0;this.s.aiInnerWidths=[];this.s.aiOuterWidths=[];d.each(this.s.dt.aoColumns,function(e,f){var g=d(f.nTh),h;if(g.filter(":visible").length){var i=g.outerWidth();0===a.s.aiOuterWidths.length&&(h=d(a.s.dt.nTable).css("border-left-width"),i+="string"===
|
290 |
+
typeof h&&-1===h.indexOf("px")?1:parseInt(h,10));a.s.aiOuterWidths.length===a.s.dt.aoColumns.length-1&&(h=d(a.s.dt.nTable).css("border-right-width"),i+="string"===typeof h&&-1===h.indexOf("px")?1:parseInt(h,10));a.s.aiOuterWidths.push(i);a.s.aiInnerWidths.push(g.width());e<a.s.iLeftColumns&&(b+=i);a.s.iTableColumns-a.s.iRightColumns<=e&&(c+=i)}else a.s.aiInnerWidths.push(0),a.s.aiOuterWidths.push(0)});this.s.iLeftWidth=b;this.s.iRightWidth=c},_fnGridSetup:function(){var a=this._fnDTOverflow(),b;this.dom.body=
|
291 |
+
this.s.dt.nTable;this.dom.header=this.s.dt.nTHead.parentNode;this.dom.header.parentNode.parentNode.style.position="relative";var c=d('<div class="DTFC_ScrollWrapper" style="position:relative; clear:both;"><div class="DTFC_LeftWrapper" style="position:absolute; top:0; left:0;" aria-hidden="true"><div class="DTFC_LeftHeadWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div><div class="DTFC_LeftBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;"><div class="DTFC_LeftBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div></div><div class="DTFC_LeftFootWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div></div><div class="DTFC_RightWrapper" style="position:absolute; top:0; right:0;" aria-hidden="true"><div class="DTFC_RightHeadWrapper" style="position:relative; top:0; left:0;"><div class="DTFC_RightHeadBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div></div><div class="DTFC_RightBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;"><div class="DTFC_RightBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div></div><div class="DTFC_RightFootWrapper" style="position:relative; top:0; left:0;"><div class="DTFC_RightFootBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div></div></div></div>')[0],
|
292 |
+
e=c.childNodes[0],f=c.childNodes[1];this.dom.grid.dt.parentNode.insertBefore(c,this.dom.grid.dt);c.appendChild(this.dom.grid.dt);this.dom.grid.wrapper=c;0<this.s.iLeftColumns&&(this.dom.grid.left.wrapper=e,this.dom.grid.left.head=e.childNodes[0],this.dom.grid.left.body=e.childNodes[1],this.dom.grid.left.liner=d("div.DTFC_LeftBodyLiner",c)[0],c.appendChild(e));0<this.s.iRightColumns&&(this.dom.grid.right.wrapper=f,this.dom.grid.right.head=f.childNodes[0],this.dom.grid.right.body=f.childNodes[1],this.dom.grid.right.liner=
|
293 |
+
d("div.DTFC_RightBodyLiner",c)[0],f.style.right=a.bar+"px",b=d("div.DTFC_RightHeadBlocker",c)[0],b.style.width=a.bar+"px",b.style.right=-a.bar+"px",this.dom.grid.right.headBlock=b,b=d("div.DTFC_RightFootBlocker",c)[0],b.style.width=a.bar+"px",b.style.right=-a.bar+"px",this.dom.grid.right.footBlock=b,c.appendChild(f));if(this.s.dt.nTFoot&&(this.dom.footer=this.s.dt.nTFoot.parentNode,0<this.s.iLeftColumns&&(this.dom.grid.left.foot=e.childNodes[2]),0<this.s.iRightColumns))this.dom.grid.right.foot=f.childNodes[2];
|
294 |
+
this.s.rtl&&d("div.DTFC_RightHeadBlocker",c).css({left:-a.bar+"px",right:""})},_fnGridLayout:function(){var a=this,b=this.dom.grid;d(b.wrapper).width();var c=this.s.dt.nTable.parentNode.offsetHeight,e=this.s.dt.nTable.parentNode.parentNode.offsetHeight,f=this._fnDTOverflow(),g=this.s.iLeftWidth,h=this.s.iRightWidth,i="rtl"===d(this.dom.body).css("direction"),k=function(b,c){f.bar?a._firefoxScrollError()?34<d(b).height()&&(b.style.width=c+f.bar+"px"):b.style.width=c+f.bar+"px":(b.style.width=c+20+
|
295 |
+
"px",b.style.paddingRight="20px",b.style.boxSizing="border-box")};f.x&&(c-=f.bar);b.wrapper.style.height=e+"px";0<this.s.iLeftColumns&&(e=b.left.wrapper,e.style.width=g+"px",e.style.height="1px",i?(e.style.left="",e.style.right=0):(e.style.left=0,e.style.right=""),b.left.body.style.height=c+"px",b.left.foot&&(b.left.foot.style.top=(f.x?f.bar:0)+"px"),k(b.left.liner,g),b.left.liner.style.height=c+"px",b.left.liner.style.maxHeight=c+"px");0<this.s.iRightColumns&&(e=b.right.wrapper,e.style.width=h+"px",
|
296 |
+
e.style.height="1px",this.s.rtl?(e.style.left=f.y?f.bar+"px":0,e.style.right=""):(e.style.left="",e.style.right=f.y?f.bar+"px":0),b.right.body.style.height=c+"px",b.right.foot&&(b.right.foot.style.top=(f.x?f.bar:0)+"px"),k(b.right.liner,h),b.right.liner.style.height=c+"px",b.right.liner.style.maxHeight=c+"px",b.right.headBlock.style.display=f.y?"block":"none",b.right.footBlock.style.display=f.y?"block":"none")},_fnDTOverflow:function(){var a=this.s.dt.nTable,b=a.parentNode,c={x:!1,y:!1,bar:this.s.dt.oScroll.iBarWidth};
|
297 |
+
a.offsetWidth>b.clientWidth&&(c.x=!0);a.offsetHeight>b.clientHeight&&(c.y=!0);return c},_fnDraw:function(a){this._fnGridLayout();this._fnCloneLeft(a);this._fnCloneRight(a);null!==this.s.fnDrawCallback&&this.s.fnDrawCallback.call(this,this.dom.clone.left,this.dom.clone.right);d(this).trigger("draw.dtfc",{leftClone:this.dom.clone.left,rightClone:this.dom.clone.right})},_fnCloneRight:function(a){if(!(0>=this.s.iRightColumns)){var b,c=[];for(b=this.s.iTableColumns-this.s.iRightColumns;b<this.s.iTableColumns;b++)this.s.dt.aoColumns[b].bVisible&&
|
298 |
+
c.push(b);this._fnClone(this.dom.clone.right,this.dom.grid.right,c,a)}},_fnCloneLeft:function(a){if(!(0>=this.s.iLeftColumns)){var b,c=[];for(b=0;b<this.s.iLeftColumns;b++)this.s.dt.aoColumns[b].bVisible&&c.push(b);this._fnClone(this.dom.clone.left,this.dom.grid.left,c,a)}},_fnCopyLayout:function(a,b,c){for(var e=[],f=[],g=[],h=0,i=a.length;h<i;h++){var k=[];k.nTr=d(a[h].nTr).clone(c,!1)[0];for(var l=0,o=this.s.iTableColumns;l<o;l++)if(-1!==d.inArray(l,b)){var q=d.inArray(a[h][l].cell,g);-1===q?(q=
|
299 |
+
d(a[h][l].cell).clone(c,!1)[0],f.push(q),g.push(a[h][l].cell),k.push({cell:q,unique:a[h][l].unique})):k.push({cell:f[q],unique:a[h][l].unique})}e.push(k)}return e},_fnClone:function(a,b,c,e){var f=this,g,h,i,k,l,o,q,n,m,j=this.s.dt;if(e){d(a.header).remove();a.header=d(this.dom.header).clone(!0,!1)[0];a.header.className+=" DTFC_Cloned";a.header.style.width="100%";b.head.appendChild(a.header);n=this._fnCopyLayout(j.aoHeader,c,!0);k=d(">thead",a.header);k.empty();g=0;for(h=n.length;g<h;g++)k[0].appendChild(n[g].nTr);
|
300 |
+
j.oApi._fnDrawHead(j,n,!0)}else{n=this._fnCopyLayout(j.aoHeader,c,!1);m=[];j.oApi._fnDetectHeader(m,d(">thead",a.header)[0]);g=0;for(h=n.length;g<h;g++){i=0;for(k=n[g].length;i<k;i++)m[g][i].cell.className=n[g][i].cell.className,d("span.DataTables_sort_icon",m[g][i].cell).each(function(){this.className=d("span.DataTables_sort_icon",n[g][i].cell)[0].className})}}this._fnEqualiseHeights("thead",this.dom.header,a.header);"auto"==this.s.sHeightMatch&&d(">tbody>tr",f.dom.body).css("height","auto");null!==
|
301 |
+
a.body&&(d(a.body).remove(),a.body=null);a.body=d(this.dom.body).clone(!0)[0];a.body.className+=" DTFC_Cloned";a.body.style.paddingBottom=j.oScroll.iBarWidth+"px";a.body.style.marginBottom=2*j.oScroll.iBarWidth+"px";null!==a.body.getAttribute("id")&&a.body.removeAttribute("id");d(">thead>tr",a.body).empty();d(">tfoot",a.body).remove();var p=d("tbody",a.body)[0];d(p).empty();if(0<j.aiDisplay.length){h=d(">thead>tr",a.body)[0];for(q=0;q<c.length;q++)l=c[q],o=d(j.aoColumns[l].nTh).clone(!0)[0],o.innerHTML=
|
302 |
+
"",k=o.style,k.paddingTop="0",k.paddingBottom="0",k.borderTopWidth="0",k.borderBottomWidth="0",k.height=0,k.width=f.s.aiInnerWidths[l]+"px",h.appendChild(o);d(">tbody>tr",f.dom.body).each(function(a){var a=f.s.dt.oFeatures.bServerSide===false?f.s.dt.aiDisplay[f.s.dt._iDisplayStart+a]:a,b=f.s.dt.aoData[a].anCells||d(this).children("td, th"),e=this.cloneNode(false);e.removeAttribute("id");e.setAttribute("data-dt-row",a);for(q=0;q<c.length;q++){l=c[q];if(b.length>0){o=d(b[l]).clone(true,true)[0];o.removeAttribute("id");
|
303 |
+
o.setAttribute("data-dt-row",a);o.setAttribute("data-dt-column",j.oApi._fnVisibleToColumnIndex(j,l));e.appendChild(o)}}p.appendChild(e)})}else d(">tbody>tr",f.dom.body).each(function(){o=this.cloneNode(true);o.className=o.className+" DTFC_NoData";d("td",o).html("");p.appendChild(o)});a.body.style.width="100%";a.body.style.margin="0";a.body.style.padding="0";j.oScroller!==t&&(h=j.oScroller.dom.force,b.forcer?b.forcer.style.height=h.style.height:(b.forcer=h.cloneNode(!0),b.liner.appendChild(b.forcer)));
|
304 |
+
b.liner.appendChild(a.body);this._fnEqualiseHeights("tbody",f.dom.body,a.body);if(null!==j.nTFoot){if(e){null!==a.footer&&a.footer.parentNode.removeChild(a.footer);a.footer=d(this.dom.footer).clone(!0,!0)[0];a.footer.className+=" DTFC_Cloned";a.footer.style.width="100%";b.foot.appendChild(a.footer);n=this._fnCopyLayout(j.aoFooter,c,!0);b=d(">tfoot",a.footer);b.empty();g=0;for(h=n.length;g<h;g++)b[0].appendChild(n[g].nTr);j.oApi._fnDrawHead(j,n,!0)}else{n=this._fnCopyLayout(j.aoFooter,c,!1);b=[];j.oApi._fnDetectHeader(b,
|
305 |
+
d(">tfoot",a.footer)[0]);g=0;for(h=n.length;g<h;g++){i=0;for(k=n[g].length;i<k;i++)b[g][i].cell.className=n[g][i].cell.className}}this._fnEqualiseHeights("tfoot",this.dom.footer,a.footer)}b=j.oApi._fnGetUniqueThs(j,d(">thead",a.header)[0]);d(b).each(function(a){l=c[a];this.style.width=f.s.aiInnerWidths[l]+"px"});null!==f.s.dt.nTFoot&&(b=j.oApi._fnGetUniqueThs(j,d(">tfoot",a.footer)[0]),d(b).each(function(a){l=c[a];this.style.width=f.s.aiInnerWidths[l]+"px"}))},_fnGetTrNodes:function(a){for(var b=
|
306 |
+
[],c=0,d=a.childNodes.length;c<d;c++)"TR"==a.childNodes[c].nodeName.toUpperCase()&&b.push(a.childNodes[c]);return b},_fnEqualiseHeights:function(a,b,c){if(!("none"==this.s.sHeightMatch&&"thead"!==a&&"tfoot"!==a)){var e,f,g=b.getElementsByTagName(a)[0],c=c.getElementsByTagName(a)[0],a=d(">"+a+">tr:eq(0)",b).children(":first");a.outerHeight();a.height();for(var g=this._fnGetTrNodes(g),b=this._fnGetTrNodes(c),h=[],c=0,a=b.length;c<a;c++)e=g[c].offsetHeight,f=b[c].offsetHeight,e=f>e?f:e,"semiauto"==this.s.sHeightMatch&&
|
307 |
+
(g[c]._DTTC_iHeight=e),h.push(e);c=0;for(a=b.length;c<a;c++)b[c].style.height=h[c]+"px",g[c].style.height=h[c]+"px"}},_firefoxScrollError:function(){if(u===t){var a=d("<div/>").css({position:"absolute",top:0,left:0,height:10,width:50,overflow:"scroll"}).appendTo("body");u=a[0].clientWidth===a[0].offsetWidth&&0!==this._fnDTOverflow().bar;a.remove()}return u}});m.defaults={iLeftColumns:1,iRightColumns:0,fnDrawCallback:null,sHeightMatch:"semiauto"};m.version="3.2.4";s.Api.register("fixedColumns()",function(){return this});
|
308 |
+
s.Api.register("fixedColumns().update()",function(){return this.iterator("table",function(a){a._oFixedColumns&&a._oFixedColumns.fnUpdate()})});s.Api.register("fixedColumns().relayout()",function(){return this.iterator("table",function(a){a._oFixedColumns&&a._oFixedColumns.fnRedrawLayout()})});s.Api.register("rows().recalcHeight()",function(){return this.iterator("row",function(a,b){a._oFixedColumns&&a._oFixedColumns.fnRecalculateHeight(this.row(b).node())})});s.Api.register("fixedColumns().rowIndex()",
|
309 |
+
function(a){a=d(a);return a.parents(".DTFC_Cloned").length?this.rows({page:"current"}).indexes()[a.index()]:this.row(a).index()});s.Api.register("fixedColumns().cellIndex()",function(a){a=d(a);if(a.parents(".DTFC_Cloned").length){var b=a.parent().index(),b=this.rows({page:"current"}).indexes()[b],a=a.parents(".DTFC_LeftWrapper").length?a.index():this.columns().flatten().length-this.context[0]._oFixedColumns.s.iRightColumns+a.index();return{row:b,column:this.column.index("toData",a),columnVisible:a}}return this.cell(a).index()});
|
310 |
+
d(r).on("init.dt.fixedColumns",function(a,b){if("dt"===a.namespace){var c=b.oInit.fixedColumns,e=s.defaults.fixedColumns;if(c||e)e=d.extend({},c,e),!1!==c&&new m(b,e)}});d.fn.dataTable.FixedColumns=m;return d.fn.DataTable.FixedColumns=m});
|
311 |
+
|
312 |
+
|
313 |
+
/*!
|
314 |
+
FixedHeader 3.1.3
|
315 |
+
©2009-2017 SpryMedia Ltd - datatables.net/license
|
316 |
+
*/
|
317 |
+
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(g){return d(g,window,document)}):"object"===typeof exports?module.exports=function(g,h){g||(g=window);if(!h||!h.fn.dataTable)h=require("datatables.net")(g,h).$;return d(h,g,g.document)}:d(jQuery,window,document)})(function(d,g,h,k){var j=d.fn.dataTable,l=0,i=function(b,a){if(!(this instanceof i))throw"FixedHeader must be initialised with the 'new' keyword.";!0===a&&(a={});b=new j.Api(b);this.c=d.extend(!0,
|
318 |
+
{},i.defaults,a);this.s={dt:b,position:{theadTop:0,tbodyTop:0,tfootTop:0,tfootBottom:0,width:0,left:0,tfootHeight:0,theadHeight:0,windowHeight:d(g).height(),visible:!0},headerMode:null,footerMode:null,autoWidth:b.settings()[0].oFeatures.bAutoWidth,namespace:".dtfc"+l++,scrollLeft:{header:-1,footer:-1},enable:!0};this.dom={floatingHeader:null,thead:d(b.table().header()),tbody:d(b.table().body()),tfoot:d(b.table().footer()),header:{host:null,floating:null,placeholder:null},footer:{host:null,floating:null,
|
319 |
+
placeholder:null}};this.dom.header.host=this.dom.thead.parent();this.dom.footer.host=this.dom.tfoot.parent();var e=b.settings()[0];if(e._fixedHeader)throw"FixedHeader already initialised on table "+e.nTable.id;e._fixedHeader=this;this._constructor()};d.extend(i.prototype,{enable:function(b){this.s.enable=b;this.c.header&&this._modeChange("in-place","header",!0);this.c.footer&&this.dom.tfoot.length&&this._modeChange("in-place","footer",!0);this.update()},headerOffset:function(b){b!==k&&(this.c.headerOffset=
|
320 |
+
b,this.update());return this.c.headerOffset},footerOffset:function(b){b!==k&&(this.c.footerOffset=b,this.update());return this.c.footerOffset},update:function(){this._positions();this._scroll(!0)},_constructor:function(){var b=this,a=this.s.dt;d(g).on("scroll"+this.s.namespace,function(){b._scroll()}).on("resize"+this.s.namespace,function(){b.s.position.windowHeight=d(g).height();b.update()});var e=d(".fh-fixedHeader");!this.c.headerOffset&&e.length&&(this.c.headerOffset=e.outerHeight());e=d(".fh-fixedFooter");
|
321 |
+
!this.c.footerOffset&&e.length&&(this.c.footerOffset=e.outerHeight());a.on("column-reorder.dt.dtfc column-visibility.dt.dtfc draw.dt.dtfc column-sizing.dt.dtfc",function(){b.update()});a.on("destroy.dtfc",function(){a.off(".dtfc");d(g).off(b.s.namespace)});this._positions();this._scroll()},_clone:function(b,a){var e=this.s.dt,c=this.dom[b],f="header"===b?this.dom.thead:this.dom.tfoot;!a&&c.floating?c.floating.removeClass("fixedHeader-floating fixedHeader-locked"):(c.floating&&(c.placeholder.remove(),
|
322 |
+
this._unsize(b),c.floating.children().detach(),c.floating.remove()),c.floating=d(e.table().node().cloneNode(!1)).css("table-layout","fixed").removeAttr("id").append(f).appendTo("body"),c.placeholder=f.clone(!1),c.placeholder.find("*[id]").removeAttr("id"),c.host.prepend(c.placeholder),this._matchWidths(c.placeholder,c.floating))},_matchWidths:function(b,a){var e=function(a){return d(a,b).map(function(){return d(this).width()}).toArray()},c=function(b,c){d(b,a).each(function(a){d(this).css({width:c[a],
|
323 |
+
minWidth:c[a]})})},f=e("th"),e=e("td");c("th",f);c("td",e)},_unsize:function(b){var a=this.dom[b].floating;a&&("footer"===b||"header"===b&&!this.s.autoWidth)?d("th, td",a).css({width:"",minWidth:""}):a&&"header"===b&&d("th, td",a).css("min-width","")},_horizontal:function(b,a){var e=this.dom[b],c=this.s.position,d=this.s.scrollLeft;e.floating&&d[b]!==a&&(e.floating.css("left",c.left-a),d[b]=a)},_modeChange:function(b,a,e){var c=this.dom[a],f=this.s.position,g=d.contains(this.dom["footer"===a?"tfoot":
|
324 |
+
"thead"][0],h.activeElement)?h.activeElement:null;if("in-place"===b){if(c.placeholder&&(c.placeholder.remove(),c.placeholder=null),this._unsize(a),"header"===a?c.host.prepend(this.dom.thead):c.host.append(this.dom.tfoot),c.floating)c.floating.remove(),c.floating=null}else"in"===b?(this._clone(a,e),c.floating.addClass("fixedHeader-floating").css("header"===a?"top":"bottom",this.c[a+"Offset"]).css("left",f.left+"px").css("width",f.width+"px"),"footer"===a&&c.floating.css("top","")):"below"===b?(this._clone(a,
|
325 |
+
e),c.floating.addClass("fixedHeader-locked").css("top",f.tfootTop-f.theadHeight).css("left",f.left+"px").css("width",f.width+"px")):"above"===b&&(this._clone(a,e),c.floating.addClass("fixedHeader-locked").css("top",f.tbodyTop).css("left",f.left+"px").css("width",f.width+"px"));g&&g!==h.activeElement&&g.focus();this.s.scrollLeft.header=-1;this.s.scrollLeft.footer=-1;this.s[a+"Mode"]=b},_positions:function(){var b=this.s.dt.table(),a=this.s.position,e=this.dom,b=d(b.node()),c=b.children("thead"),f=
|
326 |
+
b.children("tfoot"),e=e.tbody;a.visible=b.is(":visible");a.width=b.outerWidth();a.left=b.offset().left;a.theadTop=c.offset().top;a.tbodyTop=e.offset().top;a.theadHeight=a.tbodyTop-a.theadTop;f.length?(a.tfootTop=f.offset().top,a.tfootBottom=a.tfootTop+f.outerHeight(),a.tfootHeight=a.tfootBottom-a.tfootTop):(a.tfootTop=a.tbodyTop+e.outerHeight(),a.tfootBottom=a.tfootTop,a.tfootHeight=a.tfootTop)},_scroll:function(b){var a=d(h).scrollTop(),e=d(h).scrollLeft(),c=this.s.position,f;if(this.s.enable&&(this.c.header&&
|
327 |
+
(f=!c.visible||a<=c.theadTop-this.c.headerOffset?"in-place":a<=c.tfootTop-c.theadHeight-this.c.headerOffset?"in":"below",(b||f!==this.s.headerMode)&&this._modeChange(f,"header",b),this._horizontal("header",e)),this.c.footer&&this.dom.tfoot.length))a=!c.visible||a+c.windowHeight>=c.tfootBottom+this.c.footerOffset?"in-place":c.windowHeight+a>c.tbodyTop+c.tfootHeight+this.c.footerOffset?"in":"above",(b||a!==this.s.footerMode)&&this._modeChange(a,"footer",b),this._horizontal("footer",e)}});i.version=
|
328 |
+
"3.1.3";i.defaults={header:!0,footer:!1,headerOffset:0,footerOffset:0};d.fn.dataTable.FixedHeader=i;d.fn.DataTable.FixedHeader=i;d(h).on("init.dt.dtfh",function(b,a){if("dt"===b.namespace){var e=a.oInit.fixedHeader,c=j.defaults.fixedHeader;if((e||c)&&!a._fixedHeader)c=d.extend({},c,e),!1!==e&&new i(a,c)}});j.Api.register("fixedHeader()",function(){});j.Api.register("fixedHeader.adjust()",function(){return this.iterator("table",function(b){(b=b._fixedHeader)&&b.update()})});j.Api.register("fixedHeader.enable()",
|
329 |
+
function(b){return this.iterator("table",function(a){a=a._fixedHeader;b=b!==k?b:!0;a&&b!==a.s.enable&&a.enable(b)})});j.Api.register("fixedHeader.disable()",function(){return this.iterator("table",function(b){(b=b._fixedHeader)&&b.s.enable&&b.enable(!1)})});d.each(["header","footer"],function(b,a){j.Api.register("fixedHeader."+a+"Offset()",function(b){var c=this.context;return b===k?c.length&&c[0]._fixedHeader?c[0]._fixedHeader[a+"Offset"]():k:this.iterator("table",function(c){if(c=c._fixedHeader)c[a+
|
330 |
+
"Offset"](b)})})});return i});
|
331 |
+
|
332 |
+
|
333 |
+
/*!
|
334 |
+
KeyTable 2.3.2
|
335 |
+
©2009-2017 SpryMedia Ltd - datatables.net/license
|
336 |
+
*/
|
337 |
+
(function(f){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(k){return f(k,window,document)}):"object"===typeof exports?module.exports=function(k,h){k||(k=window);if(!h||!h.fn.dataTable)h=require("datatables.net")(k,h).$;return f(h,k,k.document)}:f(jQuery,window,document)})(function(f,k,h,o){var l=f.fn.dataTable,n=function(a,b){if(!l.versionCheck||!l.versionCheck("1.10.8"))throw"KeyTable requires DataTables 1.10.8 or newer";this.c=f.extend(!0,{},l.defaults.keyTable,
|
338 |
+
n.defaults,b);this.s={dt:new l.Api(a),enable:!0,focusDraw:!1,waitingForDraw:!1,lastFocus:null};this.dom={};var c=this.s.dt.settings()[0],d=c.keytable;if(d)return d;c.keytable=this;this._constructor()};f.extend(n.prototype,{blur:function(){this._blur()},enable:function(a){this.s.enable=a},focus:function(a,b){this._focus(this.s.dt.cell(a,b))},focused:function(a){if(!this.s.lastFocus)return!1;var b=this.s.lastFocus.cell.index();return a.row===b.row&&a.column===b.column},_constructor:function(){this._tabInput();
|
339 |
+
var a=this,b=this.s.dt,c=f(b.table().node());"static"===c.css("position")&&c.css("position","relative");f(b.table().body()).on("click.keyTable","th, td",function(c){if(!1!==a.s.enable){var d=b.cell(this);d.any()&&a._focus(d,null,!1,c)}});f(h).on("keydown.keyTable",function(b){a._key(b)});if(this.c.blurable)f(h).on("mousedown.keyTable",function(c){f(c.target).parents(".dataTables_filter").length&&a._blur();f(c.target).parents().filter(b.table().container()).length||f(c.target).parents("div.DTE").length||
|
340 |
+
f(c.target).parents("div.editor-datetime").length||f(c.target).parents().filter(".DTFC_Cloned").length||a._blur()});if(this.c.editor){var d=this.c.editor;d.on("open.keyTableMain",function(b,c){"inline"!==c&&a.s.enable&&(a.enable(!1),d.one("close.keyTable",function(){a.enable(!0)}))});if(this.c.editOnFocus)b.on("key-focus.keyTable key-refocus.keyTable",function(b,c,d,e){a._editor(null,e)});b.on("key.keyTable",function(b,c,d,e,f){a._editor(d,f)})}if(b.settings()[0].oFeatures.bStateSave)b.on("stateSaveParams.keyTable",
|
341 |
+
function(b,c,d){d.keyTable=a.s.lastFocus?a.s.lastFocus.cell.index():null});b.on("draw.keyTable",function(c){if(!a.s.focusDraw){var d=a.s.lastFocus;if(d&&d.node&&f(d.node).closest("body")===h.body){var d=a.s.lastFocus.relative,e=b.page.info(),j=d.row+e.start;0!==e.recordsDisplay&&(j>=e.recordsDisplay&&(j=e.recordsDisplay-1),a._focus(j,d.column,!0,c))}}});b.on("destroy.keyTable",function(){b.off(".keyTable");f(b.table().body()).off("click.keyTable","th, td");f(h.body).off("keydown.keyTable").off("click.keyTable")});
|
342 |
+
var e=b.state.loaded();if(e&&e.keyTable)b.one("init",function(){var a=b.cell(e.keyTable);a.any()&&a.focus()});else this.c.focus&&b.cell(this.c.focus).focus()},_blur:function(){if(this.s.enable&&this.s.lastFocus){var a=this.s.lastFocus.cell;f(a.node()).removeClass(this.c.className);this.s.lastFocus=null;this._updateFixedColumns(a.index().column);this._emitEvent("key-blur",[this.s.dt,a])}},_clipboardCopy:function(){var a=this.s.dt;if(this.s.lastFocus&&k.getSelection&&!k.getSelection().toString()){var b=
|
343 |
+
this.s.lastFocus.cell.render("display"),c=f("<div/>").css({height:1,width:1,overflow:"hidden",position:"fixed",top:0,left:0}),b=f("<textarea readonly/>").val(b).appendTo(c);try{c.appendTo(a.table().container()),b[0].focus(),b[0].select(),h.execCommand("copy")}catch(d){}c.remove()}},_columns:function(){var a=this.s.dt,b=a.columns(this.c.columns).indexes(),c=[];a.columns(":visible").every(function(a){-1!==b.indexOf(a)&&c.push(a)});return c},_editor:function(a,b){var c=this,d=this.s.dt,e=this.c.editor;
|
344 |
+
!f("div.DTE",this.s.lastFocus.cell.node()).length&&16!==a&&(b.stopPropagation(),13===a&&b.preventDefault(),e.one("open.keyTable",function(){e.off("cancelOpen.keyTable");c.c.editAutoSelect&&f("div.DTE_Field_InputControl input, div.DTE_Field_InputControl textarea").select();d.keys.enable(c.c.editorKeys);d.one("key-blur.editor",function(){e.displayed()&&e.submit()});e.one("close",function(){d.keys.enable(!0);d.off("key-blur.editor")})}).one("cancelOpen.keyTable",function(){e.off("open.keyTable")}).inline(this.s.lastFocus.cell.index()))},
|
345 |
+
_emitEvent:function(a,b){this.s.dt.iterator("table",function(c){f(c.nTable).triggerHandler(a,b)})},_focus:function(a,b,c,d){var e=this,m=this.s.dt,g=m.page.info(),i=this.s.lastFocus;d||(d=null);if(this.s.enable){if("number"!==typeof a){var j=a.index(),b=j.column,a=m.rows({filter:"applied",order:"applied"}).indexes().indexOf(j.row);g.serverSide&&(a+=g.start)}if(-1!==g.length&&(a<g.start||a>=g.start+g.length))this.s.focusDraw=!0,this.s.waitingForDraw=!0,m.one("draw",function(){e.s.focusDraw=!1;e.s.waitingForDraw=
|
346 |
+
!1;e._focus(a,b,o,d)}).page(Math.floor(a/g.length)).draw(!1);else if(-1!==f.inArray(b,this._columns())){g.serverSide&&(a-=g.start);g=m.cells(null,b,{search:"applied",order:"applied"}).flatten();g=m.cell(g[a]);if(i){if(i.node===g.node()){this._emitEvent("key-refocus",[this.s.dt,g,d||null]);return}this._blur()}i=f(g.node());i.addClass(this.c.className);this._updateFixedColumns(b);if(c===o||!0===c)this._scroll(f(k),f(h.body),i,"offset"),c=m.table().body().parentNode,c!==m.table().header().parentNode&&
|
347 |
+
(c=f(c.parentNode),this._scroll(c,c,i,"position"));this.s.lastFocus={cell:g,node:g.node(),relative:{row:m.rows({page:"current"}).indexes().indexOf(g.index().row),column:g.index().column}};this._emitEvent("key-focus",[this.s.dt,g,d||null]);m.state.save()}}},_key:function(a){if(this.s.waitingForDraw)a.preventDefault();else{var b=this.s.enable,c=!0===b||"navigation-only"===b;if(b)if(a.ctrlKey&&67===a.keyCode)this._clipboardCopy();else if(!(0===a.keyCode||a.ctrlKey||a.metaKey||a.altKey)&&this.s.lastFocus){var d=
|
348 |
+
this.s.dt;if(!(this.c.keys&&-1===f.inArray(a.keyCode,this.c.keys)))switch(a.keyCode){case 9:this._shift(a,a.shiftKey?"left":"right",!0);break;case 27:this.s.blurable&&!0===b&&this._blur();break;case 33:case 34:c&&(a.preventDefault(),d.page(33===a.keyCode?"previous":"next").draw(!1));break;case 35:case 36:c&&(a.preventDefault(),b=d.cells({page:"current"}).indexes(),c=this._columns(),this._focus(d.cell(b[35===a.keyCode?b.length-1:c[0]]),null,!0,a));break;case 37:c&&this._shift(a,"left");break;case 38:c&&
|
349 |
+
this._shift(a,"up");break;case 39:c&&this._shift(a,"right");break;case 40:c&&this._shift(a,"down");break;default:!0===b&&this._emitEvent("key",[d,a.keyCode,this.s.lastFocus.cell,a])}}}},_scroll:function(a,b,c,d){var e=c[d](),f=c.outerHeight(),g=c.outerWidth(),i=b.scrollTop(),j=b.scrollLeft(),h=a.height(),a=a.width();"position"===d&&(e.top+=parseInt(c.closest("table").css("top"),10));e.top<i&&b.scrollTop(e.top);e.left<j&&b.scrollLeft(e.left);e.top+f>i+h&&f<h&&b.scrollTop(e.top+f-h);e.left+g>j+a&&g<
|
350 |
+
a&&b.scrollLeft(e.left+g-a)},_shift:function(a,b,c){var d=this.s.dt,e=d.page.info(),h=e.recordsDisplay,g=this.s.lastFocus.cell,i=this._columns();if(g){var j=d.rows({filter:"applied",order:"applied"}).indexes().indexOf(g.index().row);e.serverSide&&(j+=e.start);d=d.columns(i).indexes().indexOf(g.index().column);e=i[d];"right"===b?d>=i.length-1?(j++,e=i[0]):e=i[d+1]:"left"===b?0===d?(j--,e=i[i.length-1]):e=i[d-1]:"up"===b?j--:"down"===b&&j++;0<=j&&j<h&&-1!==f.inArray(e,i)?(a.preventDefault(),this._focus(j,
|
351 |
+
e,!0,a)):!c||!this.c.blurable?a.preventDefault():this._blur()}},_tabInput:function(){var a=this,b=this.s.dt,c=null!==this.c.tabIndex?this.c.tabIndex:b.settings()[0].iTabIndex;if(-1!=c)f('<div><input type="text" tabindex="'+c+'"/></div>').css({position:"absolute",height:1,width:0,overflow:"hidden"}).insertBefore(b.table().node()).children().on("focus",function(c){b.cell(":eq(0)",{page:"current"}).any()&&a._focus(b.cell(":eq(0)","0:visible",{page:"current"}),null,!0,c)})},_updateFixedColumns:function(a){var b=
|
352 |
+
this.s.dt,c=b.settings()[0];if(c._oFixedColumns){var d=c.aoColumns.length-c._oFixedColumns.s.iRightColumns;(a<c._oFixedColumns.s.iLeftColumns||a>=d)&&b.fixedColumns().update()}}});n.defaults={blurable:!0,className:"focus",columns:"",editor:null,editorKeys:"navigation-only",editAutoSelect:!0,editOnFocus:!1,focus:null,keys:null,tabIndex:null};n.version="2.3.2";f.fn.dataTable.KeyTable=n;f.fn.DataTable.KeyTable=n;l.Api.register("cell.blur()",function(){return this.iterator("table",function(a){a.keytable&&
|
353 |
+
a.keytable.blur()})});l.Api.register("cell().focus()",function(){return this.iterator("cell",function(a,b,c){a.keytable&&a.keytable.focus(b,c)})});l.Api.register("keys.disable()",function(){return this.iterator("table",function(a){a.keytable&&a.keytable.enable(!1)})});l.Api.register("keys.enable()",function(a){return this.iterator("table",function(b){b.keytable&&b.keytable.enable(a===o?!0:a)})});l.ext.selector.cell.push(function(a,b,c){var b=b.focused,a=a.keytable,d=[];if(!a||b===o)return c;for(var e=
|
354 |
+
0,f=c.length;e<f;e++)(!0===b&&a.focused(c[e])||!1===b&&!a.focused(c[e]))&&d.push(c[e]);return d});f(h).on("preInit.dt.dtk",function(a,b){if("dt"===a.namespace){var c=b.oInit.keys,d=l.defaults.keys;if(c||d)d=f.extend({},d,c),!1!==c&&new n(b,d)}});return n});
|
355 |
+
|
356 |
+
|
357 |
+
/*!
|
358 |
+
Responsive 2.2.1
|
359 |
+
2014-2017 SpryMedia Ltd - datatables.net/license
|
360 |
+
*/
|
361 |
+
(function(c){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(l){return c(l,window,document)}):"object"===typeof exports?module.exports=function(l,k){l||(l=window);if(!k||!k.fn.dataTable)k=require("datatables.net")(l,k).$;return c(k,l,l.document)}:c(jQuery,window,document)})(function(c,l,k,q){function s(b,a,c){var e=a+"-"+c;if(m[e])return m[e];for(var f=[],b=b.cell(a,c).node().childNodes,a=0,c=b.length;a<c;a++)f.push(b[a]);return m[e]=f}function r(b,a,c){var e=a+
|
362 |
+
"-"+c;if(m[e]){for(var b=b.cell(a,c).node(),c=m[e][0].parentNode.childNodes,a=[],f=0,g=c.length;f<g;f++)a.push(c[f]);c=0;for(f=a.length;c<f;c++)b.appendChild(a[c]);m[e]=q}}var o=c.fn.dataTable,j=function(b,a){if(!o.versionCheck||!o.versionCheck("1.10.10"))throw"DataTables Responsive requires DataTables 1.10.10 or newer";this.s={dt:new o.Api(b),columns:[],current:[]};this.s.dt.settings()[0].responsive||(a&&"string"===typeof a.details?a.details={type:a.details}:a&&!1===a.details?a.details={type:!1}:
|
363 |
+
a&&!0===a.details&&(a.details={type:"inline"}),this.c=c.extend(!0,{},j.defaults,o.defaults.responsive,a),b.responsive=this,this._constructor())};c.extend(j.prototype,{_constructor:function(){var b=this,a=this.s.dt,d=a.settings()[0],e=c(l).width();a.settings()[0]._responsive=this;c(l).on("resize.dtr orientationchange.dtr",o.util.throttle(function(){var a=c(l).width();a!==e&&(b._resize(),e=a)}));d.oApi._fnCallbackReg(d,"aoRowCreatedCallback",function(e){-1!==c.inArray(!1,b.s.current)&&c(">td, >th",
|
364 |
+
e).each(function(e){e=a.column.index("toData",e);!1===b.s.current[e]&&c(this).css("display","none")})});a.on("destroy.dtr",function(){a.off(".dtr");c(a.table().body()).off(".dtr");c(l).off("resize.dtr orientationchange.dtr");c.each(b.s.current,function(a,c){!1===c&&b._setColumnVis(a,!0)})});this.c.breakpoints.sort(function(a,b){return a.width<b.width?1:a.width>b.width?-1:0});this._classLogic();this._resizeAuto();d=this.c.details;!1!==d.type&&(b._detailsInit(),a.on("column-visibility.dtr",function(a,
|
365 |
+
c,e,d,h){h&&(b._classLogic(),b._resizeAuto(),b._resize())}),a.on("draw.dtr",function(){b._redrawChildren()}),c(a.table().node()).addClass("dtr-"+d.type));a.on("column-reorder.dtr",function(){b._classLogic();b._resizeAuto();b._resize()});a.on("column-sizing.dtr",function(){b._resizeAuto();b._resize()});a.on("preXhr.dtr",function(){var c=[];a.rows().every(function(){this.child.isShown()&&c.push(this.id(true))});a.one("draw.dtr",function(){b._resizeAuto();b._resize();a.rows(c).every(function(){b._detailsDisplay(this,
|
366 |
+
false)})})});a.on("init.dtr",function(){b._resizeAuto();b._resize();c.inArray(false,b.s.current)&&a.columns.adjust()});this._resize()},_columnsVisiblity:function(b){var a=this.s.dt,d=this.s.columns,e,f,g=d.map(function(a,b){return{columnIdx:b,priority:a.priority}}).sort(function(a,b){return a.priority!==b.priority?a.priority-b.priority:a.columnIdx-b.columnIdx}),i=c.map(d,function(a){return a.auto&&null===a.minWidth?!1:!0===a.auto?"-":-1!==c.inArray(b,a.includeIn)}),n=0;e=0;for(f=i.length;e<f;e++)!0===
|
367 |
+
i[e]&&(n+=d[e].minWidth);e=a.settings()[0].oScroll;e=e.sY||e.sX?e.iBarWidth:0;a=a.table().container().offsetWidth-e-n;e=0;for(f=i.length;e<f;e++)d[e].control&&(a-=d[e].minWidth);n=!1;e=0;for(f=g.length;e<f;e++){var h=g[e].columnIdx;"-"===i[h]&&(!d[h].control&&d[h].minWidth)&&(n||0>a-d[h].minWidth?(n=!0,i[h]=!1):i[h]=!0,a-=d[h].minWidth)}g=!1;e=0;for(f=d.length;e<f;e++)if(!d[e].control&&!d[e].never&&!i[e]){g=!0;break}e=0;for(f=d.length;e<f;e++)d[e].control&&(i[e]=g);-1===c.inArray(!0,i)&&(i[0]=!0);
|
368 |
+
return i},_classLogic:function(){var b=this,a=this.c.breakpoints,d=this.s.dt,e=d.columns().eq(0).map(function(a){var b=this.column(a),e=b.header().className,a=d.settings()[0].aoColumns[a].responsivePriority;a===q&&(b=c(b.header()).data("priority"),a=b!==q?1*b:1E4);return{className:e,includeIn:[],auto:!1,control:!1,never:e.match(/\bnever\b/)?!0:!1,priority:a}}),f=function(a,b){var d=e[a].includeIn;-1===c.inArray(b,d)&&d.push(b)},g=function(c,d,h,g){if(h)if("max-"===h){g=b._find(d).width;d=0;for(h=
|
369 |
+
a.length;d<h;d++)a[d].width<=g&&f(c,a[d].name)}else if("min-"===h){g=b._find(d).width;d=0;for(h=a.length;d<h;d++)a[d].width>=g&&f(c,a[d].name)}else{if("not-"===h){d=0;for(h=a.length;d<h;d++)-1===a[d].name.indexOf(g)&&f(c,a[d].name)}}else e[c].includeIn.push(d)};e.each(function(b,e){for(var d=b.className.split(" "),f=!1,j=0,l=d.length;j<l;j++){var k=c.trim(d[j]);if("all"===k){f=!0;b.includeIn=c.map(a,function(a){return a.name});return}if("none"===k||b.never){f=!0;return}if("control"===k){f=!0;b.control=
|
370 |
+
!0;return}c.each(a,function(a,b){var c=b.name.split("-"),d=k.match(RegExp("(min\\-|max\\-|not\\-)?("+c[0]+")(\\-[_a-zA-Z0-9])?"));d&&(f=!0,d[2]===c[0]&&d[3]==="-"+c[1]?g(e,b.name,d[1],d[2]+d[3]):d[2]===c[0]&&!d[3]&&g(e,b.name,d[1],d[2]))})}f||(b.auto=!0)});this.s.columns=e},_detailsDisplay:function(b,a){var d=this,e=this.s.dt,f=this.c.details;if(f&&!1!==f.type){var g=f.display(b,a,function(){return f.renderer(e,b[0],d._detailsObj(b[0]))});(!0===g||!1===g)&&c(e.table().node()).triggerHandler("responsive-display.dt",
|
371 |
+
[e,b,g,a])}},_detailsInit:function(){var b=this,a=this.s.dt,d=this.c.details;"inline"===d.type&&(d.target="td:first-child, th:first-child");a.on("draw.dtr",function(){b._tabIndexes()});b._tabIndexes();c(a.table().body()).on("keyup.dtr","td, th",function(a){a.keyCode===13&&c(this).data("dtr-keyboard")&&c(this).click()});var e=d.target;c(a.table().body()).on("click.dtr mousedown.dtr mouseup.dtr","string"===typeof e?e:"td, th",function(d){if(c(a.table().node()).hasClass("collapsed")&&c.inArray(c(this).closest("tr").get(0),
|
372 |
+
a.rows().nodes().toArray())!==-1){if(typeof e==="number"){var g=e<0?a.columns().eq(0).length+e:e;if(a.cell(this).index().column!==g)return}g=a.row(c(this).closest("tr"));d.type==="click"?b._detailsDisplay(g,false):d.type==="mousedown"?c(this).css("outline","none"):d.type==="mouseup"&&c(this).blur().css("outline","")}})},_detailsObj:function(b){var a=this,d=this.s.dt;return c.map(this.s.columns,function(c,f){if(!c.never&&!c.control)return{title:d.settings()[0].aoColumns[f].sTitle,data:d.cell(b,f).render(a.c.orthogonal),
|
373 |
+
hidden:d.column(f).visible()&&!a.s.current[f],columnIndex:f,rowIndex:b}})},_find:function(b){for(var a=this.c.breakpoints,c=0,e=a.length;c<e;c++)if(a[c].name===b)return a[c]},_redrawChildren:function(){var b=this,a=this.s.dt;a.rows({page:"current"}).iterator("row",function(c,e){a.row(e);b._detailsDisplay(a.row(e),!0)})},_resize:function(){var b=this,a=this.s.dt,d=c(l).width(),e=this.c.breakpoints,f=e[0].name,g=this.s.columns,i,n=this.s.current.slice();for(i=e.length-1;0<=i;i--)if(d<=e[i].width){f=
|
374 |
+
e[i].name;break}var h=this._columnsVisiblity(f);this.s.current=h;e=!1;i=0;for(d=g.length;i<d;i++)if(!1===h[i]&&!g[i].never&&!g[i].control){e=!0;break}c(a.table().node()).toggleClass("collapsed",e);var j=!1,k=0;a.columns().eq(0).each(function(a,c){!0===h[c]&&k++;h[c]!==n[c]&&(j=!0,b._setColumnVis(a,h[c]))});j&&(this._redrawChildren(),c(a.table().node()).trigger("responsive-resize.dt",[a,this.s.current]),0===a.page.info().recordsDisplay&&c("td",a.table().body()).eq(0).attr("colspan",k))},_resizeAuto:function(){var b=
|
375 |
+
this.s.dt,a=this.s.columns;if(this.c.auto&&-1!==c.inArray(!0,c.map(a,function(a){return a.auto}))){c.isEmptyObject(m)||c.each(m,function(a){a=a.split("-");r(b,1*a[0],1*a[1])});b.table().node();var d=b.table().node().cloneNode(!1),e=c(b.table().header().cloneNode(!1)).appendTo(d),f=c(b.table().body()).clone(!1,!1).empty().appendTo(d),g=b.columns().header().filter(function(a){return b.column(a).visible()}).to$().clone(!1).css("display","table-cell").css("min-width",0);c(f).append(c(b.rows({page:"current"}).nodes()).clone(!1)).find("th, td").css("display",
|
376 |
+
"");if(f=b.table().footer()){var f=c(f.cloneNode(!1)).appendTo(d),i=b.columns().footer().filter(function(a){return b.column(a).visible()}).to$().clone(!1).css("display","table-cell");c("<tr/>").append(i).appendTo(f)}c("<tr/>").append(g).appendTo(e);"inline"===this.c.details.type&&c(d).addClass("dtr-inline collapsed");c(d).find("[name]").removeAttr("name");d=c("<div/>").css({width:1,height:1,overflow:"hidden",clear:"both"}).append(d);d.insertBefore(b.table().node());g.each(function(c){c=b.column.index("fromVisible",
|
377 |
+
c);a[c].minWidth=this.offsetWidth||0});d.remove()}},_setColumnVis:function(b,a){var d=this.s.dt,e=a?"":"none";c(d.column(b).header()).css("display",e);c(d.column(b).footer()).css("display",e);d.column(b).nodes().to$().css("display",e);c.isEmptyObject(m)||d.cells(null,b).indexes().each(function(a){r(d,a.row,a.column)})},_tabIndexes:function(){var b=this.s.dt,a=b.cells({page:"current"}).nodes().to$(),d=b.settings()[0],e=this.c.details.target;a.filter("[data-dtr-keyboard]").removeData("[data-dtr-keyboard]");
|
378 |
+
a="number"===typeof e?":eq("+e+")":e;"td:first-child, th:first-child"===a&&(a=">td:first-child, >th:first-child");c(a,b.rows({page:"current"}).nodes()).attr("tabIndex",d.iTabIndex).data("dtr-keyboard",1)}});j.breakpoints=[{name:"desktop",width:Infinity},{name:"tablet-l",width:1024},{name:"tablet-p",width:768},{name:"mobile-l",width:480},{name:"mobile-p",width:320}];j.display={childRow:function(b,a,d){if(a){if(c(b.node()).hasClass("parent"))return b.child(d(),"child").show(),!0}else{if(b.child.isShown())return b.child(!1),
|
379 |
+
c(b.node()).removeClass("parent"),!1;b.child(d(),"child").show();c(b.node()).addClass("parent");return!0}},childRowImmediate:function(b,a,d){if(!a&&b.child.isShown()||!b.responsive.hasHidden())return b.child(!1),c(b.node()).removeClass("parent"),!1;b.child(d(),"child").show();c(b.node()).addClass("parent");return!0},modal:function(b){return function(a,d,e){if(d)c("div.dtr-modal-content").empty().append(e());else{var f=function(){g.remove();c(k).off("keypress.dtr")},g=c('<div class="dtr-modal"/>').append(c('<div class="dtr-modal-display"/>').append(c('<div class="dtr-modal-content"/>').append(e())).append(c('<div class="dtr-modal-close">×</div>').click(function(){f()}))).append(c('<div class="dtr-modal-background"/>').click(function(){f()})).appendTo("body");
|
380 |
+
c(k).on("keyup.dtr",function(a){27===a.keyCode&&(a.stopPropagation(),f())})}b&&b.header&&c("div.dtr-modal-content").prepend("<h2>"+b.header(a)+"</h2>")}}};var m={};j.renderer={listHiddenNodes:function(){return function(b,a,d){var e=c('<ul data-dtr-index="'+a+'" class="dtr-details"/>'),f=!1;c.each(d,function(a,d){d.hidden&&(c('<li data-dtr-index="'+d.columnIndex+'" data-dt-row="'+d.rowIndex+'" data-dt-column="'+d.columnIndex+'"><span class="dtr-title">'+d.title+"</span> </li>").append(c('<span class="dtr-data"/>').append(s(b,
|
381 |
+
d.rowIndex,d.columnIndex))).appendTo(e),f=!0)});return f?e:!1}},listHidden:function(){return function(b,a,d){return(b=c.map(d,function(a){return a.hidden?'<li data-dtr-index="'+a.columnIndex+'" data-dt-row="'+a.rowIndex+'" data-dt-column="'+a.columnIndex+'"><span class="dtr-title">'+a.title+'</span> <span class="dtr-data">'+a.data+"</span></li>":""}).join(""))?c('<ul data-dtr-index="'+a+'" class="dtr-details"/>').append(b):!1}},tableAll:function(b){b=c.extend({tableClass:""},b);return function(a,
|
382 |
+
d,e){a=c.map(e,function(a){return'<tr data-dt-row="'+a.rowIndex+'" data-dt-column="'+a.columnIndex+'"><td>'+a.title+":</td> <td>"+a.data+"</td></tr>"}).join("");return c('<table class="'+b.tableClass+' dtr-details" width="100%"/>').append(a)}}};j.defaults={breakpoints:j.breakpoints,auto:!0,details:{display:j.display.childRow,renderer:j.renderer.listHidden(),target:0,type:"inline"},orthogonal:"display"};var p=c.fn.dataTable.Api;p.register("responsive()",function(){return this});p.register("responsive.index()",
|
383 |
+
function(b){b=c(b);return{column:b.data("dtr-index"),row:b.parent().data("dtr-index")}});p.register("responsive.rebuild()",function(){return this.iterator("table",function(b){b._responsive&&b._responsive._classLogic()})});p.register("responsive.recalc()",function(){return this.iterator("table",function(b){b._responsive&&(b._responsive._resizeAuto(),b._responsive._resize())})});p.register("responsive.hasHidden()",function(){var b=this.context[0];return b._responsive?-1!==c.inArray(!1,b._responsive.s.current):
|
384 |
+
!1});p.registerPlural("columns().responsiveHidden()","column().responsiveHidden()",function(){return this.iterator("column",function(b,a){return b._responsive?b._responsive.s.current[a]:!1},1)});j.version="2.2.1";c.fn.dataTable.Responsive=j;c.fn.DataTable.Responsive=j;c(k).on("preInit.dt.dtr",function(b,a){if("dt"===b.namespace&&(c(a.nTable).hasClass("responsive")||c(a.nTable).hasClass("dt-responsive")||a.oInit.responsive||o.defaults.responsive)){var d=a.oInit.responsive;!1!==d&&new j(a,c.isPlainObject(d)?
|
385 |
+
d:{})}});return j});
|
386 |
+
|
387 |
+
|
388 |
+
/*!
|
389 |
+
RowReorder 1.2.3
|
390 |
+
2015-2017 SpryMedia Ltd - datatables.net/license
|
391 |
+
*/
|
392 |
+
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(f){return d(f,window,document)}):"object"===typeof exports?module.exports=function(f,g){f||(f=window);if(!g||!g.fn.dataTable)g=require("datatables.net")(f,g).$;return d(g,f,f.document)}:d(jQuery,window,document)})(function(d,f,g,m){var h=d.fn.dataTable,k=function(c,b){if(!h.versionCheck||!h.versionCheck("1.10.8"))throw"DataTables RowReorder requires DataTables 1.10.8 or newer";this.c=d.extend(!0,{},h.defaults.rowReorder,
|
393 |
+
k.defaults,b);this.s={bodyTop:null,dt:new h.Api(c),getDataFn:h.ext.oApi._fnGetObjectDataFn(this.c.dataSrc),middles:null,scroll:{},scrollInterval:null,setDataFn:h.ext.oApi._fnSetObjectDataFn(this.c.dataSrc),start:{top:0,left:0,offsetTop:0,offsetLeft:0,nodes:[]},windowHeight:0,documentOuterHeight:0,domCloneOuterHeight:0};this.dom={clone:null,dtScroll:d("div.dataTables_scrollBody",this.s.dt.table().container())};var a=this.s.dt.settings()[0],e=a.rowreorder;if(e)return e;a.rowreorder=this;this._constructor()};
|
394 |
+
d.extend(k.prototype,{_constructor:function(){var c=this,b=this.s.dt,a=d(b.table().node());"static"===a.css("position")&&a.css("position","relative");d(b.table().container()).on("mousedown.rowReorder touchstart.rowReorder",this.c.selector,function(a){if(c.c.enable){var i=d(this).closest("tr"),j=b.row(i);if(j.any())return c._emitEvent("pre-row-reorder",{node:j.node(),index:j.index()}),c._mouseDown(a,i),!1}});b.on("destroy.rowReorder",function(){d(b.table().container()).off(".rowReorder");b.off(".rowReorder")})},
|
395 |
+
_cachePositions:function(){var c=this.s.dt,b=d(c.table().node()).find("thead").outerHeight(),a=d.unique(c.rows({page:"current"}).nodes().toArray()),e=d.map(a,function(a){return d(a).position().top-b}),a=d.map(e,function(a,b){return e.length<b-1?(a+e[b+1])/2:(a+a+d(c.row(":last-child").node()).outerHeight())/2});this.s.middles=a;this.s.bodyTop=d(c.table().body()).offset().top;this.s.windowHeight=d(f).height();this.s.documentOuterHeight=d(g).outerHeight()},_clone:function(c){var b=d(this.s.dt.table().node().cloneNode(!1)).addClass("dt-rowReorder-float").append("<tbody/>").append(c.clone(!1)),
|
396 |
+
a=c.outerWidth(),e=c.outerHeight(),i=c.children().map(function(){return d(this).width()});b.width(a).height(e).find("tr").children().each(function(a){this.style.width=i[a]+"px"});b.appendTo("body");this.dom.clone=b;this.s.domCloneOuterHeight=b.outerHeight()},_clonePosition:function(c){var b=this.s.start,a=this._eventToPage(c,"Y")-b.top,c=this._eventToPage(c,"X")-b.left,e=this.c.snapX,a=a+b.offsetTop,b=!0===e?b.offsetLeft:"number"===typeof e?b.offsetLeft+e:c+b.offsetLeft;0>a?a=0:a+this.s.domCloneOuterHeight>
|
397 |
+
this.s.documentOuterHeight&&(a=this.s.documentOuterHeight-this.s.domCloneOuterHeight);this.dom.clone.css({top:a,left:b})},_emitEvent:function(c,b){this.s.dt.iterator("table",function(a){d(a.nTable).triggerHandler(c+".dt",b)})},_eventToPage:function(c,b){return-1!==c.type.indexOf("touch")?c.originalEvent.touches[0]["page"+b]:c["page"+b]},_mouseDown:function(c,b){var a=this,e=this.s.dt,i=this.s.start,j=b.offset();i.top=this._eventToPage(c,"Y");i.left=this._eventToPage(c,"X");i.offsetTop=j.top;i.offsetLeft=
|
398 |
+
j.left;i.nodes=d.unique(e.rows({page:"current"}).nodes().toArray());this._cachePositions();this._clone(b);this._clonePosition(c);this.dom.target=b;b.addClass("dt-rowReorder-moving");d(g).on("mouseup.rowReorder touchend.rowReorder",function(b){a._mouseUp(b)}).on("mousemove.rowReorder touchmove.rowReorder",function(b){a._mouseMove(b)});d(f).width()===d(g).width()&&d(g.body).addClass("dt-rowReorder-noOverflow");e=this.dom.dtScroll;this.s.scroll={windowHeight:d(f).height(),windowWidth:d(f).width(),dtTop:e.length?
|
399 |
+
e.offset().top:null,dtLeft:e.length?e.offset().left:null,dtHeight:e.length?e.outerHeight():null,dtWidth:e.length?e.outerWidth():null}},_mouseMove:function(c){this._clonePosition(c);for(var b=this._eventToPage(c,"Y")-this.s.bodyTop,a=this.s.middles,e=null,i=this.s.dt,j=i.table().body(),g=0,f=a.length;g<f;g++)if(b<a[g]){e=g;break}null===e&&(e=a.length);if(null===this.s.lastInsert||this.s.lastInsert!==e)0===e?this.dom.target.prependTo(j):(b=d.unique(i.rows({page:"current"}).nodes().toArray()),e>this.s.lastInsert?
|
400 |
+
this.dom.target.insertAfter(b[e-1]):this.dom.target.insertBefore(b[e])),this._cachePositions(),this.s.lastInsert=e;this._shiftScroll(c)},_mouseUp:function(){var c=this,b=this.s.dt,a,e,i=this.c.dataSrc;this.dom.clone.remove();this.dom.clone=null;this.dom.target.removeClass("dt-rowReorder-moving");d(g).off(".rowReorder");d(g.body).removeClass("dt-rowReorder-noOverflow");clearInterval(this.s.scrollInterval);this.s.scrollInterval=null;var j=this.s.start.nodes,f=d.unique(b.rows({page:"current"}).nodes().toArray()),
|
401 |
+
k={},h=[],l=[],n=this.s.getDataFn,m=this.s.setDataFn;a=0;for(e=j.length;a<e;a++)if(j[a]!==f[a]){var o=b.row(f[a]).id(),s=b.row(f[a]).data(),p=b.row(j[a]).data();o&&(k[o]=n(p));h.push({node:f[a],oldData:n(s),newData:n(p),newPosition:a,oldPosition:d.inArray(f[a],j)});l.push(f[a])}var q=[h,{dataSrc:i,nodes:l,values:k,triggerRow:b.row(this.dom.target)}];this._emitEvent("row-reorder",q);var r=function(){if(c.c.update){a=0;for(e=h.length;a<e;a++){var d=b.row(h[a].node).data();m(d,h[a].newData);b.columns().every(function(){this.dataSrc()===
|
402 |
+
i&&b.cell(h[a].node,this.index()).invalidate("data")})}c._emitEvent("row-reordered",q);b.draw(!1)}};this.c.editor?(this.c.enable=!1,this.c.editor.edit(l,!1,d.extend({submit:"changed"},this.c.formOptions)).multiSet(i,k).one("submitUnsuccessful.rowReorder",function(){b.draw(!1)}).one("submitSuccess.rowReorder",function(){r()}).one("submitComplete",function(){c.c.enable=!0;c.c.editor.off(".rowReorder")}).submit()):r()},_shiftScroll:function(c){var b=this,a=this.s.scroll,e=!1,d=c.pageY-g.body.scrollTop,
|
403 |
+
f,h;65>d?f=-5:d>a.windowHeight-65&&(f=5);null!==a.dtTop&&c.pageY<a.dtTop+65?h=-5:null!==a.dtTop&&c.pageY>a.dtTop+a.dtHeight-65&&(h=5);f||h?(a.windowVert=f,a.dtVert=h,e=!0):this.s.scrollInterval&&(clearInterval(this.s.scrollInterval),this.s.scrollInterval=null);!this.s.scrollInterval&&e&&(this.s.scrollInterval=setInterval(function(){if(a.windowVert)g.body.scrollTop=g.body.scrollTop+a.windowVert;if(a.dtVert){var c=b.dom.dtScroll[0];if(a.dtVert)c.scrollTop=c.scrollTop+a.dtVert}},20))}});k.defaults={dataSrc:0,
|
404 |
+
editor:null,enable:!0,formOptions:{},selector:"td:first-child",snapX:!1,update:!0};var l=d.fn.dataTable.Api;l.register("rowReorder()",function(){return this});l.register("rowReorder.enable()",function(c){c===m&&(c=!0);return this.iterator("table",function(b){b.rowreorder&&(b.rowreorder.c.enable=c)})});l.register("rowReorder.disable()",function(){return this.iterator("table",function(c){c.rowreorder&&(c.rowreorder.c.enable=!1)})});k.version="1.2.3";d.fn.dataTable.RowReorder=k;d.fn.DataTable.RowReorder=
|
405 |
+
k;d(g).on("init.dt.dtr",function(c,b){if("dt"===c.namespace){var a=b.oInit.rowReorder,e=h.defaults.rowReorder;if(a||e)e=d.extend({},a,e),!1!==a&&new k(b,e)}});return k});
|
406 |
+
|
407 |
+
|
408 |
+
/*!
|
409 |
+
Scroller 1.4.4
|
410 |
+
©2011-2018 SpryMedia Ltd - datatables.net/license
|
411 |
+
*/
|
412 |
+
(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(g){return e(g,window,document)}):"object"===typeof exports?module.exports=function(g,j){g||(g=window);if(!j||!j.fn.dataTable)j=require("datatables.net")(g,j).$;return e(j,g,g.document)}:e(jQuery,window,document)})(function(e,g,j,l){var m=e.fn.dataTable,h=function(a,b){this instanceof h?(b===l&&(b={}),this.s={dt:e.fn.dataTable.Api(a).settings()[0],tableTop:0,tableBottom:0,redrawTop:0,redrawBottom:0,autoHeight:!0,
|
413 |
+
viewportRows:0,stateTO:null,drawTO:null,heights:{jump:null,page:null,virtual:null,scroll:null,row:null,viewport:null},topRowFloat:0,scrollDrawDiff:null,loaderVisible:!1,forceReposition:!1},this.s=e.extend(this.s,h.oDefaults,b),this.s.heights.row=this.s.rowHeight,this.dom={force:j.createElement("div"),scroller:null,table:null,loader:null},this.s.dt.oScroller||(this.s.dt.oScroller=this,this._fnConstruct())):alert("Scroller warning: Scroller must be initialised with the 'new' keyword.")};e.extend(h.prototype,
|
414 |
+
{fnRowToPixels:function(a,b,c){a=c?this._domain("virtualToPhysical",a*this.s.heights.row):this.s.baseScrollTop+(a-this.s.baseRowTop)*this.s.heights.row;return b||b===l?parseInt(a,10):a},fnPixelsToRow:function(a,b,c){var d=a-this.s.baseScrollTop,a=c?this._domain("physicalToVirtual",a)/this.s.heights.row:d/this.s.heights.row+this.s.baseRowTop;return b||b===l?parseInt(a,10):a},fnScrollToRow:function(a,b){var c=this,d=!1,f=this.fnRowToPixels(a),i=a-(this.s.displayBuffer-1)/2*this.s.viewportRows;0>i&&
|
415 |
+
(i=0);if((f>this.s.redrawBottom||f<this.s.redrawTop)&&this.s.dt._iDisplayStart!==i)d=!0,f=this.fnRowToPixels(a,!1,!0),this.s.redrawTop<f&&f<this.s.redrawBottom&&(this.s.forceReposition=!0,b=!1);"undefined"==typeof b||b?(this.s.ani=d,e(this.dom.scroller).animate({scrollTop:f},function(){setTimeout(function(){c.s.ani=!1},25)})):e(this.dom.scroller).scrollTop(f)},fnMeasure:function(a){this.s.autoHeight&&this._fnCalcRowHeight();var b=this.s.heights;b.row&&(b.viewport=e.contains(j,this.dom.scroller)?e(this.dom.scroller).height():
|
416 |
+
this._parseHeight(e(this.dom.scroller).css("height")),b.viewport||(b.viewport=this._parseHeight(e(this.dom.scroller).css("max-height"))),this.s.viewportRows=parseInt(b.viewport/b.row,10)+1,this.s.dt._iDisplayLength=this.s.viewportRows*this.s.displayBuffer);(a===l||a)&&this.s.dt.oInstance.fnDraw(!1)},fnPageInfo:function(){var a=this.dom.scroller.scrollTop,b=this.s.dt.fnRecordsDisplay(),c=Math.ceil(this.fnPixelsToRow(a+this.s.heights.viewport,!1,this.s.ani));return{start:Math.floor(this.fnPixelsToRow(a,
|
417 |
+
!1,this.s.ani)),end:b<c?b-1:c-1}},_fnConstruct:function(){var a=this;if(this.s.dt.oFeatures.bPaginate){this.dom.force.style.position="relative";this.dom.force.style.top="0px";this.dom.force.style.left="0px";this.dom.force.style.width="1px";this.dom.scroller=e("div."+this.s.dt.oClasses.sScrollBody,this.s.dt.nTableWrapper)[0];this.dom.scroller.appendChild(this.dom.force);this.dom.scroller.style.position="relative";this.dom.table=e(">table",this.dom.scroller)[0];this.dom.table.style.position="absolute";
|
418 |
+
this.dom.table.style.top="0px";this.dom.table.style.left="0px";e(this.s.dt.nTableWrapper).addClass("DTS");this.s.loadingIndicator&&(this.dom.loader=e('<div class="dataTables_processing DTS_Loading">'+this.s.dt.oLanguage.sLoadingRecords+"</div>").css("display","none"),e(this.dom.scroller.parentNode).css("position","relative").append(this.dom.loader));this.s.heights.row&&"auto"!=this.s.heights.row&&(this.s.autoHeight=!1);this.fnMeasure(!1);this.s.ingnoreScroll=!0;this.s.stateSaveThrottle=this.s.dt.oApi._fnThrottle(function(){a.s.dt.oApi._fnSaveState(a.s.dt)},
|
419 |
+
500);e(this.dom.scroller).on("scroll.DTS",function(){a._fnScroll.call(a)});e(this.dom.scroller).on("touchstart.DTS",function(){a._fnScroll.call(a)});this.s.dt.aoDrawCallback.push({fn:function(){a.s.dt.bInitialised&&a._fnDrawCallback.call(a)},sName:"Scroller"});e(g).on("resize.DTS",function(){a.fnMeasure(false);a._fnInfo()});var b=!0;this.s.dt.oApi._fnCallbackReg(this.s.dt,"aoStateSaveParams",function(c,d){if(b&&a.s.dt.oLoadedState){d.iScroller=a.s.dt.oLoadedState.iScroller;d.iScrollerTopRow=a.s.dt.oLoadedState.iScrollerTopRow;
|
420 |
+
b=false}else{d.iScroller=a.dom.scroller.scrollTop;d.iScrollerTopRow=a.s.topRowFloat}},"Scroller_State");this.s.dt.oLoadedState&&(this.s.topRowFloat=this.s.dt.oLoadedState.iScrollerTopRow||0);e(this.s.dt.nTable).one("init.dt",function(){a.fnMeasure()});this.s.dt.aoDestroyCallback.push({sName:"Scroller",fn:function(){e(g).off("resize.DTS");e(a.dom.scroller).off("touchstart.DTS scroll.DTS");e(a.s.dt.nTableWrapper).removeClass("DTS");e("div.DTS_Loading",a.dom.scroller.parentNode).remove();e(a.s.dt.nTable).off("init.dt");
|
421 |
+
a.dom.table.style.position="";a.dom.table.style.top="";a.dom.table.style.left=""}})}else this.s.dt.oApi._fnLog(this.s.dt,0,"Pagination must be enabled for Scroller")},_fnScroll:function(){var a=this,b=this.s.heights,c=this.dom.scroller.scrollTop,d;if(!this.s.skip&&!this.s.ingnoreScroll)if(this.s.dt.bFiltered||this.s.dt.bSorted)this.s.lastScrollTop=0;else{this._fnInfo();clearTimeout(this.s.stateTO);this.s.stateTO=setTimeout(function(){a.s.dt.oApi._fnSaveState(a.s.dt)},250);if(this.s.forceReposition||
|
422 |
+
c<this.s.redrawTop||c>this.s.redrawBottom){var f=Math.ceil((this.s.displayBuffer-1)/2*this.s.viewportRows);Math.abs(c-this.s.lastScrollTop)>b.viewport||this.s.ani||this.s.forceReposition?(d=parseInt(this._domain("physicalToVirtual",c)/b.row,10)-f,this.s.topRowFloat=this._domain("physicalToVirtual",c)/b.row):(d=this.fnPixelsToRow(c)-f,this.s.topRowFloat=this.fnPixelsToRow(c,!1));this.s.forceReposition=!1;0>=d?d=0:d+this.s.dt._iDisplayLength>this.s.dt.fnRecordsDisplay()?(d=this.s.dt.fnRecordsDisplay()-
|
423 |
+
this.s.dt._iDisplayLength,0>d&&(d=0)):0!==d%2&&d++;if(d!=this.s.dt._iDisplayStart&&(this.s.tableTop=e(this.s.dt.nTable).offset().top,this.s.tableBottom=e(this.s.dt.nTable).height()+this.s.tableTop,b=function(){if(a.s.scrollDrawReq===null)a.s.scrollDrawReq=c;a.s.dt._iDisplayStart=d;a.s.dt.oApi._fnDraw(a.s.dt)},this.s.dt.oFeatures.bServerSide?(clearTimeout(this.s.drawTO),this.s.drawTO=setTimeout(b,this.s.serverWait)):b(),this.dom.loader&&!this.s.loaderVisible))this.dom.loader.css("display","block"),
|
424 |
+
this.s.loaderVisible=!0}else this.s.topRowFloat=this._domain("physicalToVirtual",c)/b.row;this.s.lastScrollTop=c;this.s.stateSaveThrottle()}},_domain:function(a,b){var c=this.s.heights,d;if(c.virtual===c.scroll)return b;var e=(c.scroll-c.viewport)/2,i=(c.virtual-c.viewport)/2;d=i/(e*e);if("virtualToPhysical"===a){if(b<i)return Math.pow(b/d,0.5);b=2*i-b;return 0>b?c.scroll:2*e-Math.pow(b/d,0.5)}if("physicalToVirtual"===a){if(b<e)return b*b*d;b=2*e-b;return 0>b?c.virtual:2*i-b*b*d}},_parseHeight:function(a){var b,
|
425 |
+
c=/^([+-]?(?:\d+(?:\.\d+)?|\.\d+))(px|em|rem|vh)$/.exec(a);if(null===c)return 0;a=parseFloat(c[1]);c=c[2];"px"===c?b=a:"vh"===c?b=a/100*e(g).height():"rem"===c?b=a*parseFloat(e(":root").css("font-size")):"em"===c&&(b=a*parseFloat(e("body").css("font-size")));return b?b:0},_fnDrawCallback:function(){var a=this,b=this.s.heights,c=this.dom.scroller.scrollTop,d=e(this.s.dt.nTable).height(),f=this.s.dt._iDisplayStart,i=this.s.dt._iDisplayLength,h=this.s.dt.fnRecordsDisplay();this.s.skip=!0;this._fnScrollForce();
|
426 |
+
c=0===f?this.s.topRowFloat*b.row:f+i>=h?b.scroll-(h-this.s.topRowFloat)*b.row:this._domain("virtualToPhysical",this.s.topRowFloat*b.row);this.dom.scroller.scrollTop=c;this.s.baseScrollTop=c;this.s.baseRowTop=this.s.topRowFloat;var g=c-(this.s.topRowFloat-f)*b.row;0===f?g=0:f+i>=h&&(g=b.scroll-d);this.dom.table.style.top=g+"px";this.s.tableTop=g;this.s.tableBottom=d+this.s.tableTop;d=(c-this.s.tableTop)*this.s.boundaryScale;this.s.redrawTop=c-d;this.s.redrawBottom=c+d>b.scroll-b.viewport-b.row?b.scroll-
|
427 |
+
b.viewport-b.row:c+d;this.s.skip=!1;this.s.dt.oFeatures.bStateSave&&null!==this.s.dt.oLoadedState&&"undefined"!=typeof this.s.dt.oLoadedState.iScroller?((c=(this.s.dt.sAjaxSource||a.s.dt.ajax)&&!this.s.dt.oFeatures.bServerSide?!0:!1)&&2==this.s.dt.iDraw||!c&&1==this.s.dt.iDraw)&&setTimeout(function(){e(a.dom.scroller).scrollTop(a.s.dt.oLoadedState.iScroller);a.s.redrawTop=a.s.dt.oLoadedState.iScroller-b.viewport/2;setTimeout(function(){a.s.ingnoreScroll=!1},0)},0):a.s.ingnoreScroll=!1;this.s.dt.oFeatures.bInfo&&
|
428 |
+
setTimeout(function(){a._fnInfo.call(a)},0);this.dom.loader&&this.s.loaderVisible&&(this.dom.loader.css("display","none"),this.s.loaderVisible=!1)},_fnScrollForce:function(){var a=this.s.heights;a.virtual=a.row*this.s.dt.fnRecordsDisplay();a.scroll=a.virtual;1E6<a.scroll&&(a.scroll=1E6);this.dom.force.style.height=a.scroll>this.s.heights.row?a.scroll+"px":this.s.heights.row+"px"},_fnCalcRowHeight:function(){var a=this.s.dt,b=a.nTable,c=b.cloneNode(!1),d=e("<tbody/>").appendTo(c),f=e('<div class="'+
|
429 |
+
a.oClasses.sWrapper+' DTS"><div class="'+a.oClasses.sScrollWrapper+'"><div class="'+a.oClasses.sScrollBody+'"></div></div></div>');for(e("tbody tr:lt(4)",b).clone().appendTo(d);3>e("tr",d).length;)d.append("<tr><td> </td></tr>");e("div."+a.oClasses.sScrollBody,f).append(c);a=this.s.dt.nHolding||b.parentNode;e(a).is(":visible")||(a="body");f.appendTo(a);this.s.heights.row=e("tr",d).eq(1).outerHeight();f.remove()},_fnInfo:function(){if(this.s.dt.oFeatures.bInfo){var a=this.s.dt,b=a.oLanguage,c=
|
430 |
+
this.dom.scroller.scrollTop,d=Math.floor(this.fnPixelsToRow(c,!1,this.s.ani)+1),f=a.fnRecordsTotal(),i=a.fnRecordsDisplay(),c=Math.ceil(this.fnPixelsToRow(c+this.s.heights.viewport,!1,this.s.ani)),c=i<c?i:c,g=a.fnFormatNumber(d),h=a.fnFormatNumber(c),j=a.fnFormatNumber(f),k=a.fnFormatNumber(i),g=0===a.fnRecordsDisplay()&&a.fnRecordsDisplay()==a.fnRecordsTotal()?b.sInfoEmpty+b.sInfoPostFix:0===a.fnRecordsDisplay()?b.sInfoEmpty+" "+b.sInfoFiltered.replace("_MAX_",j)+b.sInfoPostFix:a.fnRecordsDisplay()==
|
431 |
+
a.fnRecordsTotal()?b.sInfo.replace("_START_",g).replace("_END_",h).replace("_MAX_",j).replace("_TOTAL_",k)+b.sInfoPostFix:b.sInfo.replace("_START_",g).replace("_END_",h).replace("_MAX_",j).replace("_TOTAL_",k)+" "+b.sInfoFiltered.replace("_MAX_",a.fnFormatNumber(a.fnRecordsTotal()))+b.sInfoPostFix;(b=b.fnInfoCallback)&&(g=b.call(a.oInstance,a,d,c,f,i,g));d=a.aanFeatures.i;if("undefined"!=typeof d){f=0;for(i=d.length;f<i;f++)e(d[f]).html(g)}e(a.nTable).triggerHandler("info.dt")}}});h.defaults={trace:!1,
|
432 |
+
rowHeight:"auto",serverWait:200,displayBuffer:9,boundaryScale:0.5,loadingIndicator:!1};h.oDefaults=h.defaults;h.version="1.4.4";"function"==typeof e.fn.dataTable&&"function"==typeof e.fn.dataTableExt.fnVersionCheck&&e.fn.dataTableExt.fnVersionCheck("1.10.0")?e.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var b=a.oInit;new h(a,b.scroller||b.oScroller||{})},cFeature:"S",sFeature:"Scroller"}):alert("Warning: Scroller requires DataTables 1.10.0 or greater - www.datatables.net/download");e(j).on("preInit.dt.dtscroller",
|
433 |
+
function(a,b){if("dt"===a.namespace){var c=b.oInit.scroller,d=m.defaults.scroller;if(c||d)d=e.extend({},c,d),!1!==c&&new h(b,d)}});e.fn.dataTable.Scroller=h;e.fn.DataTable.Scroller=h;var k=e.fn.dataTable.Api;k.register("scroller()",function(){return this});k.register("scroller().rowToPixels()",function(a,b,c){var d=this.context;if(d.length&&d[0].oScroller)return d[0].oScroller.fnRowToPixels(a,b,c)});k.register("scroller().pixelsToRow()",function(a,b,c){var d=this.context;if(d.length&&d[0].oScroller)return d[0].oScroller.fnPixelsToRow(a,
|
434 |
+
b,c)});k.register("scroller().scrollToRow()",function(a,b){this.iterator("table",function(c){c.oScroller&&c.oScroller.fnScrollToRow(a,b)});return this});k.register("row().scrollTo()",function(a){var b=this;this.iterator("row",function(c,d){if(c.oScroller){var e=b.rows({order:"applied",search:"applied"}).indexes().indexOf(d);c.oScroller.fnScrollToRow(e,a)}});return this});k.register("scroller.measure()",function(a){this.iterator("table",function(b){b.oScroller&&b.oScroller.fnMeasure(a)});return this});
|
435 |
+
k.register("scroller.page()",function(){var a=this.context;if(a.length&&a[0].oScroller)return a[0].oScroller.fnPageInfo()});return h});
|
436 |
+
|
437 |
+
|
438 |
+
/*!
|
439 |
+
Select for DataTables 1.2.5
|
440 |
+
2015-2018 SpryMedia Ltd - datatables.net/license/mit
|
441 |
+
*/
|
442 |
+
(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(j){return e(j,window,document)}):"object"===typeof exports?module.exports=function(j,m){j||(j=window);if(!m||!m.fn.dataTable)m=require("datatables.net")(j,m).$;return e(m,j,j.document)}:e(jQuery,window,document)})(function(e,j,m,h){function v(a,c,b){var d;d=function(b,c){if(b>c)var d=c,c=b,b=d;var f=!1;return a.columns(":visible").indexes().filter(function(a){a===b&&(f=!0);return a===c?(f=!1,!0):f})};var f=
|
443 |
+
function(b,c){var d=a.rows({search:"applied"}).indexes();if(d.indexOf(b)>d.indexOf(c))var f=c,c=b,b=f;var e=!1;return d.filter(function(a){a===b&&(e=!0);return a===c?(e=!1,!0):e})};!a.cells({selected:!0}).any()&&!b?(d=d(0,c.column),b=f(0,c.row)):(d=d(b.column,c.column),b=f(b.row,c.row));b=a.cells(b,d).flatten();a.cells(c,{selected:!0}).any()?a.cells(b).deselect():a.cells(b).select()}function r(a){var c=a.settings()[0]._select.selector;e(a.table().container()).off("mousedown.dtSelect",c).off("mouseup.dtSelect",
|
444 |
+
c).off("click.dtSelect",c);e("body").off("click.dtSelect"+a.table().node().id)}function x(a){var c=e(a.table().container()),b=a.settings()[0],d=b._select.selector;c.on("mousedown.dtSelect",d,function(b){if(b.shiftKey||b.metaKey||b.ctrlKey)c.css("-moz-user-select","none").one("selectstart.dtSelect",d,function(){return!1})}).on("mouseup.dtSelect",d,function(){c.css("-moz-user-select","")}).on("click.dtSelect",d,function(b){var c=a.select.items();if(j.getSelection){var d=j.getSelection();if((!d.anchorNode||
|
445 |
+
e(d.anchorNode).closest("table")[0]===a.table().node())&&""!==e.trim(d.toString()))return}d=a.settings()[0];if(e(b.target).closest("div.dataTables_wrapper")[0]==a.table().container()){var k=a.cell(e(b.target).closest("td, th"));if(k.any()){var g=e.Event("user-select.dt");i(a,g,[c,k,b]);g.isDefaultPrevented()||(g=k.index(),"row"===c?(c=g.row,s(b,a,d,"row",c)):"column"===c?(c=k.index().column,s(b,a,d,"column",c)):"cell"===c&&(c=k.index(),s(b,a,d,"cell",c)),d._select_lastCell=g)}}});e("body").on("click.dtSelect"+
|
446 |
+
a.table().node().id,function(c){b._select.blurable&&!e(c.target).parents().filter(a.table().container()).length&&(0!==e(c.target).parents("html").length&&!e(c.target).parents("div.DTE").length)&&p(b,!0)})}function i(a,c,b,d){if(!d||a.flatten().length)"string"===typeof c&&(c+=".dt"),b.unshift(a),e(a.table().node()).trigger(c,b)}function y(a){var c=a.settings()[0];if(c._select.info&&c.aanFeatures.i&&"api"!==a.select.style()){var b=a.rows({selected:!0}).flatten().length,d=a.columns({selected:!0}).flatten().length,
|
447 |
+
f=a.cells({selected:!0}).flatten().length,l=function(b,c,d){b.append(e('<span class="select-item"/>').append(a.i18n("select."+c+"s",{_:"%d "+c+"s selected","0":"",1:"1 "+c+" selected"},d)))};e.each(c.aanFeatures.i,function(c,a){var a=e(a),g=e('<span class="select-info"/>');l(g,"row",b);l(g,"column",d);l(g,"cell",f);var h=a.children("span.select-info");h.length&&h.remove();""!==g.text()&&a.append(g)})}}function z(a,c,b,d){var f=a[c+"s"]({search:"applied"}).indexes(),d=e.inArray(d,f),l=e.inArray(b,
|
448 |
+
f);if(!a[c+"s"]({selected:!0}).any()&&-1===d)f.splice(e.inArray(b,f)+1,f.length);else{if(d>l)var g=l,l=d,d=g;f.splice(l+1,f.length);f.splice(0,d)}a[c](b,{selected:!0}).any()?(f.splice(e.inArray(b,f),1),a[c+"s"](f).deselect()):a[c+"s"](f).select()}function p(a,c){if(c||"single"===a._select.style){var b=new g.Api(a);b.rows({selected:!0}).deselect();b.columns({selected:!0}).deselect();b.cells({selected:!0}).deselect()}}function s(a,c,b,d,f){var e=c.select.style(),g=c[d](f,{selected:!0}).any();"os"===
|
449 |
+
e?a.ctrlKey||a.metaKey?c[d](f).select(!g):a.shiftKey?"cell"===d?v(c,f,b._select_lastCell||null):z(c,d,f,b._select_lastCell?b._select_lastCell[d]:null):(a=c[d+"s"]({selected:!0}),g&&1===a.flatten().length?c[d](f).deselect():(a.deselect(),c[d](f).select())):"multi+shift"==e?a.shiftKey?"cell"===d?v(c,f,b._select_lastCell||null):z(c,d,f,b._select_lastCell?b._select_lastCell[d]:null):c[d](f).select(!g):c[d](f).select(!g)}function q(a,c){return function(b){return b.i18n("buttons."+a,c)}}function t(a){a=
|
450 |
+
a._eventNamespace;return"draw.dt.DT"+a+" select.dt.DT"+a+" deselect.dt.DT"+a}var g=e.fn.dataTable;g.select={};g.select.version="1.2.5";g.select.init=function(a){var c=a.settings()[0],b=c.oInit.select,d=g.defaults.select,b=b===h?d:b,d="row",f="api",l=!1,w=!0,k="td, th",j="selected",i=!1;c._select={};if(!0===b)f="os",i=!0;else if("string"===typeof b)f=b,i=!0;else if(e.isPlainObject(b)&&(b.blurable!==h&&(l=b.blurable),b.info!==h&&(w=b.info),b.items!==h&&(d=b.items),b.style!==h&&(f=b.style,i=!0),b.selector!==
|
451 |
+
h&&(k=b.selector),b.className!==h))j=b.className;a.select.selector(k);a.select.items(d);a.select.style(f);a.select.blurable(l);a.select.info(w);c._select.className=j;e.fn.dataTable.ext.order["select-checkbox"]=function(b,c){return this.api().column(c,{order:"index"}).nodes().map(function(c){return"row"===b._select.items?e(c).parent().hasClass(b._select.className):"cell"===b._select.items?e(c).hasClass(b._select.className):!1})};!i&&e(a.table().node()).hasClass("selectable")&&a.select.style("os")};
|
452 |
+
e.each([{type:"row",prop:"aoData"},{type:"column",prop:"aoColumns"}],function(a,c){g.ext.selector[c.type].push(function(b,a,f){var a=a.selected,e,g=[];if(!0!==a&&!1!==a)return f;for(var k=0,h=f.length;k<h;k++)e=b[c.prop][f[k]],(!0===a&&!0===e._select_selected||!1===a&&!e._select_selected)&&g.push(f[k]);return g})});g.ext.selector.cell.push(function(a,c,b){var c=c.selected,d,f=[];if(c===h)return b;for(var e=0,g=b.length;e<g;e++)d=a.aoData[b[e].row],(!0===c&&d._selected_cells&&!0===d._selected_cells[b[e].column]||
|
453 |
+
!1===c&&(!d._selected_cells||!d._selected_cells[b[e].column]))&&f.push(b[e]);return f});var n=g.Api.register,o=g.Api.registerPlural;n("select()",function(){return this.iterator("table",function(a){g.select.init(new g.Api(a))})});n("select.blurable()",function(a){return a===h?this.context[0]._select.blurable:this.iterator("table",function(c){c._select.blurable=a})});n("select.info()",function(a){return y===h?this.context[0]._select.info:this.iterator("table",function(c){c._select.info=a})});n("select.items()",
|
454 |
+
function(a){return a===h?this.context[0]._select.items:this.iterator("table",function(c){c._select.items=a;i(new g.Api(c),"selectItems",[a])})});n("select.style()",function(a){return a===h?this.context[0]._select.style:this.iterator("table",function(c){c._select.style=a;if(!c._select_init){var b=new g.Api(c);c.aoRowCreatedCallback.push({fn:function(b,a,d){a=c.aoData[d];a._select_selected&&e(b).addClass(c._select.className);b=0;for(d=c.aoColumns.length;b<d;b++)(c.aoColumns[b]._select_selected||a._selected_cells&&
|
455 |
+
a._selected_cells[b])&&e(a.anCells[b]).addClass(c._select.className)},sName:"select-deferRender"});b.on("preXhr.dt.dtSelect",function(){var c=b.rows({selected:!0}).ids(!0).filter(function(b){return b!==h}),a=b.cells({selected:!0}).eq(0).map(function(a){var c=b.row(a.row).id(!0);return c?{row:c,column:a.column}:h}).filter(function(b){return b!==h});b.one("draw.dt.dtSelect",function(){b.rows(c).select();a.any()&&a.each(function(a){b.cells(a.row,a.column).select()})})});b.on("draw.dtSelect.dt select.dtSelect.dt deselect.dtSelect.dt info.dt",
|
456 |
+
function(){y(b)});b.on("destroy.dtSelect",function(){r(b);b.off(".dtSelect")})}var d=new g.Api(c);r(d);"api"!==a&&x(d);i(new g.Api(c),"selectStyle",[a])})});n("select.selector()",function(a){return a===h?this.context[0]._select.selector:this.iterator("table",function(c){r(new g.Api(c));c._select.selector=a;"api"!==c._select.style&&x(new g.Api(c))})});o("rows().select()","row().select()",function(a){var c=this;if(!1===a)return this.deselect();this.iterator("row",function(b,a){p(b);b.aoData[a]._select_selected=
|
457 |
+
!0;e(b.aoData[a].nTr).addClass(b._select.className)});this.iterator("table",function(b,a){i(c,"select",["row",c[a]],!0)});return this});o("columns().select()","column().select()",function(a){var c=this;if(!1===a)return this.deselect();this.iterator("column",function(b,a){p(b);b.aoColumns[a]._select_selected=!0;var c=(new g.Api(b)).column(a);e(c.header()).addClass(b._select.className);e(c.footer()).addClass(b._select.className);c.nodes().to$().addClass(b._select.className)});this.iterator("table",
|
458 |
+
function(b,a){i(c,"select",["column",c[a]],!0)});return this});o("cells().select()","cell().select()",function(a){var c=this;if(!1===a)return this.deselect();this.iterator("cell",function(b,a,c){p(b);a=b.aoData[a];a._selected_cells===h&&(a._selected_cells=[]);a._selected_cells[c]=!0;a.anCells&&e(a.anCells[c]).addClass(b._select.className)});this.iterator("table",function(a,d){i(c,"select",["cell",c[d]],!0)});return this});o("rows().deselect()","row().deselect()",function(){var a=this;this.iterator("row",
|
459 |
+
function(a,b){a.aoData[b]._select_selected=!1;e(a.aoData[b].nTr).removeClass(a._select.className)});this.iterator("table",function(c,b){i(a,"deselect",["row",a[b]],!0)});return this});o("columns().deselect()","column().deselect()",function(){var a=this;this.iterator("column",function(a,b){a.aoColumns[b]._select_selected=!1;var d=new g.Api(a),f=d.column(b);e(f.header()).removeClass(a._select.className);e(f.footer()).removeClass(a._select.className);d.cells(null,b).indexes().each(function(b){var d=
|
460 |
+
a.aoData[b.row],f=d._selected_cells;d.anCells&&(!f||!f[b.column])&&e(d.anCells[b.column]).removeClass(a._select.className)})});this.iterator("table",function(c,b){i(a,"deselect",["column",a[b]],!0)});return this});o("cells().deselect()","cell().deselect()",function(){var a=this;this.iterator("cell",function(a,b,d){b=a.aoData[b];b._selected_cells[d]=!1;b.anCells&&!a.aoColumns[d]._select_selected&&e(b.anCells[d]).removeClass(a._select.className)});this.iterator("table",function(c,b){i(a,"deselect",
|
461 |
+
["cell",a[b]],!0)});return this});var u=0;e.extend(g.ext.buttons,{selected:{text:q("selected","Selected"),className:"buttons-selected",limitTo:["rows","columns","cells"],init:function(a,c,b){var d=this;b._eventNamespace=".select"+u++;a.on(t(b),function(){d.enable(-1!==e.inArray("rows",b.limitTo)&&a.rows({selected:!0}).any()||-1!==e.inArray("columns",b.limitTo)&&a.columns({selected:!0}).any()||-1!==e.inArray("cells",b.limitTo)&&a.cells({selected:!0}).any()?!0:!1)});this.disable()},destroy:function(a,
|
462 |
+
c,b){a.off(b._eventNamespace)}},selectedSingle:{text:q("selectedSingle","Selected single"),className:"buttons-selected-single",init:function(a,c,b){var d=this;b._eventNamespace=".select"+u++;a.on(t(b),function(){var b=a.rows({selected:!0}).flatten().length+a.columns({selected:!0}).flatten().length+a.cells({selected:!0}).flatten().length;d.enable(1===b)});this.disable()},destroy:function(a,c,b){a.off(b._eventNamespace)}},selectAll:{text:q("selectAll","Select all"),className:"buttons-select-all",action:function(){this[this.select.items()+
|
463 |
+
"s"]().select()}},selectNone:{text:q("selectNone","Deselect all"),className:"buttons-select-none",action:function(){p(this.settings()[0],!0)},init:function(a,c,b){var d=this;b._eventNamespace=".select"+u++;a.on(t(b),function(){var b=a.rows({selected:!0}).flatten().length+a.columns({selected:!0}).flatten().length+a.cells({selected:!0}).flatten().length;d.enable(0<b)});this.disable()},destroy:function(a,c,b){a.off(b._eventNamespace)}}});e.each(["Row","Column","Cell"],function(a,c){var b=c.toLowerCase();
|
464 |
+
g.ext.buttons["select"+c+"s"]={text:q("select"+c+"s","Select "+b+"s"),className:"buttons-select-"+b+"s",action:function(){this.select.items(b)},init:function(a){var c=this;a.on("selectItems.dt.DT",function(a,d,e){c.active(e===b)})}}});e(m).on("preInit.dt.dtSelect",function(a,c){"dt"===a.namespace&&g.select.init(new g.Api(c))});return g.select});
|
465 |
+
|
466 |
+
|
common/vendor/datatables/extensions/FixedHeader/css/fixedHeader.dataTables.css
DELETED
@@ -1,19 +0,0 @@
|
|
1 |
-
table.fixedHeader-floating {
|
2 |
-
position: fixed !important;
|
3 |
-
background-color: white;
|
4 |
-
}
|
5 |
-
|
6 |
-
table.fixedHeader-floating.no-footer {
|
7 |
-
border-bottom-width: 0;
|
8 |
-
}
|
9 |
-
|
10 |
-
table.fixedHeader-locked {
|
11 |
-
position: absolute !important;
|
12 |
-
background-color: white;
|
13 |
-
}
|
14 |
-
|
15 |
-
@media print {
|
16 |
-
table.fixedHeader-floating {
|
17 |
-
display: none;
|
18 |
-
}
|
19 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/FixedHeader/css/fixedHeader.dataTables.min.css
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
table.fixedHeader-floating{position:fixed !important;background-color:white}table.fixedHeader-floating.no-footer{border-bottom-width:0}table.fixedHeader-locked{position:absolute !important;background-color:white}@media print{table.fixedHeader-floating{display:none}}
|
|
common/vendor/datatables/extensions/FixedHeader/js/dataTables.fixedHeader.js
DELETED
@@ -1,672 +0,0 @@
|
|
1 |
-
/*! FixedHeader 3.1.2
|
2 |
-
* ©2009-2016 SpryMedia Ltd - datatables.net/license
|
3 |
-
*/
|
4 |
-
|
5 |
-
/**
|
6 |
-
* @summary FixedHeader
|
7 |
-
* @description Fix a table's header or footer, so it is always visible while
|
8 |
-
* scrolling
|
9 |
-
* @version 3.1.2
|
10 |
-
* @file dataTables.fixedHeader.js
|
11 |
-
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
12 |
-
* @contact www.sprymedia.co.uk/contact
|
13 |
-
* @copyright Copyright 2009-2016 SpryMedia Ltd.
|
14 |
-
*
|
15 |
-
* This source file is free software, available under the following license:
|
16 |
-
* MIT license - http://datatables.net/license/mit
|
17 |
-
*
|
18 |
-
* This source file is distributed in the hope that it will be useful, but
|
19 |
-
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
20 |
-
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
21 |
-
*
|
22 |
-
* For details please refer to: http://www.datatables.net
|
23 |
-
*/
|
24 |
-
|
25 |
-
(function( factory ){
|
26 |
-
if ( typeof define === 'function' && define.amd ) {
|
27 |
-
// AMD
|
28 |
-
define( ['jquery', 'datatables.net'], function ( $ ) {
|
29 |
-
return factory( $, window, document );
|
30 |
-
} );
|
31 |
-
}
|
32 |
-
else if ( typeof exports === 'object' ) {
|
33 |
-
// CommonJS
|
34 |
-
module.exports = function (root, $) {
|
35 |
-
if ( ! root ) {
|
36 |
-
root = window;
|
37 |
-
}
|
38 |
-
|
39 |
-
if ( ! $ || ! $.fn.dataTable ) {
|
40 |
-
$ = require('datatables.net')(root, $).$;
|
41 |
-
}
|
42 |
-
|
43 |
-
return factory( $, root, root.document );
|
44 |
-
};
|
45 |
-
}
|
46 |
-
else {
|
47 |
-
// Browser
|
48 |
-
factory( jQuery, window, document );
|
49 |
-
}
|
50 |
-
}(function( $, window, document, undefined ) {
|
51 |
-
'use strict';
|
52 |
-
var DataTable = $.fn.dataTable;
|
53 |
-
|
54 |
-
|
55 |
-
var _instCounter = 0;
|
56 |
-
|
57 |
-
var FixedHeader = function ( dt, config ) {
|
58 |
-
// Sanity check - you just know it will happen
|
59 |
-
if ( ! (this instanceof FixedHeader) ) {
|
60 |
-
throw "FixedHeader must be initialised with the 'new' keyword.";
|
61 |
-
}
|
62 |
-
|
63 |
-
// Allow a boolean true for defaults
|
64 |
-
if ( config === true ) {
|
65 |
-
config = {};
|
66 |
-
}
|
67 |
-
|
68 |
-
dt = new DataTable.Api( dt );
|
69 |
-
|
70 |
-
this.c = $.extend( true, {}, FixedHeader.defaults, config );
|
71 |
-
|
72 |
-
this.s = {
|
73 |
-
dt: dt,
|
74 |
-
position: {
|
75 |
-
theadTop: 0,
|
76 |
-
tbodyTop: 0,
|
77 |
-
tfootTop: 0,
|
78 |
-
tfootBottom: 0,
|
79 |
-
width: 0,
|
80 |
-
left: 0,
|
81 |
-
tfootHeight: 0,
|
82 |
-
theadHeight: 0,
|
83 |
-
windowHeight: $(window).height(),
|
84 |
-
visible: true
|
85 |
-
},
|
86 |
-
headerMode: null,
|
87 |
-
footerMode: null,
|
88 |
-
autoWidth: dt.settings()[0].oFeatures.bAutoWidth,
|
89 |
-
namespace: '.dtfc'+(_instCounter++),
|
90 |
-
scrollLeft: {
|
91 |
-
header: -1,
|
92 |
-
footer: -1
|
93 |
-
},
|
94 |
-
enable: true
|
95 |
-
};
|
96 |
-
|
97 |
-
this.dom = {
|
98 |
-
floatingHeader: null,
|
99 |
-
thead: $(dt.table().header()),
|
100 |
-
tbody: $(dt.table().body()),
|
101 |
-
tfoot: $(dt.table().footer()),
|
102 |
-
header: {
|
103 |
-
host: null,
|
104 |
-
floating: null,
|
105 |
-
placeholder: null
|
106 |
-
},
|
107 |
-
footer: {
|
108 |
-
host: null,
|
109 |
-
floating: null,
|
110 |
-
placeholder: null
|
111 |
-
}
|
112 |
-
};
|
113 |
-
|
114 |
-
this.dom.header.host = this.dom.thead.parent();
|
115 |
-
this.dom.footer.host = this.dom.tfoot.parent();
|
116 |
-
|
117 |
-
var dtSettings = dt.settings()[0];
|
118 |
-
if ( dtSettings._fixedHeader ) {
|
119 |
-
throw "FixedHeader already initialised on table "+dtSettings.nTable.id;
|
120 |
-
}
|
121 |
-
|
122 |
-
dtSettings._fixedHeader = this;
|
123 |
-
|
124 |
-
this._constructor();
|
125 |
-
};
|
126 |
-
|
127 |
-
|
128 |
-
/*
|
129 |
-
* Variable: FixedHeader
|
130 |
-
* Purpose: Prototype for FixedHeader
|
131 |
-
* Scope: global
|
132 |
-
*/
|
133 |
-
$.extend( FixedHeader.prototype, {
|
134 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
135 |
-
* API methods
|
136 |
-
*/
|
137 |
-
|
138 |
-
/**
|
139 |
-
* Enable / disable the fixed elements
|
140 |
-
*
|
141 |
-
* @param {boolean} enable `true` to enable, `false` to disable
|
142 |
-
*/
|
143 |
-
enable: function ( enable )
|
144 |
-
{
|
145 |
-
this.s.enable = enable;
|
146 |
-
|
147 |
-
if ( this.c.header ) {
|
148 |
-
this._modeChange( 'in-place', 'header', true );
|
149 |
-
}
|
150 |
-
|
151 |
-
if ( this.c.footer && this.dom.tfoot.length ) {
|
152 |
-
this._modeChange( 'in-place', 'footer', true );
|
153 |
-
}
|
154 |
-
|
155 |
-
this.update();
|
156 |
-
},
|
157 |
-
|
158 |
-
/**
|
159 |
-
* Set header offset
|
160 |
-
*
|
161 |
-
* @param {int} new value for headerOffset
|
162 |
-
*/
|
163 |
-
headerOffset: function ( offset )
|
164 |
-
{
|
165 |
-
if ( offset !== undefined ) {
|
166 |
-
this.c.headerOffset = offset;
|
167 |
-
this.update();
|
168 |
-
}
|
169 |
-
|
170 |
-
return this.c.headerOffset;
|
171 |
-
},
|
172 |
-
|
173 |
-
/**
|
174 |
-
* Set footer offset
|
175 |
-
*
|
176 |
-
* @param {int} new value for footerOffset
|
177 |
-
*/
|
178 |
-
footerOffset: function ( offset )
|
179 |
-
{
|
180 |
-
if ( offset !== undefined ) {
|
181 |
-
this.c.footerOffset = offset;
|
182 |
-
this.update();
|
183 |
-
}
|
184 |
-
|
185 |
-
return this.c.footerOffset;
|
186 |
-
},
|
187 |
-
|
188 |
-
|
189 |
-
/**
|
190 |
-
* Recalculate the position of the fixed elements and force them into place
|
191 |
-
*/
|
192 |
-
update: function ()
|
193 |
-
{
|
194 |
-
this._positions();
|
195 |
-
this._scroll( true );
|
196 |
-
},
|
197 |
-
|
198 |
-
|
199 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
200 |
-
* Constructor
|
201 |
-
*/
|
202 |
-
|
203 |
-
/**
|
204 |
-
* FixedHeader constructor - adding the required event listeners and
|
205 |
-
* simple initialisation
|
206 |
-
*
|
207 |
-
* @private
|
208 |
-
*/
|
209 |
-
_constructor: function ()
|
210 |
-
{
|
211 |
-
var that = this;
|
212 |
-
var dt = this.s.dt;
|
213 |
-
|
214 |
-
$(window)
|
215 |
-
.on( 'scroll'+this.s.namespace, function () {
|
216 |
-
that._scroll();
|
217 |
-
} )
|
218 |
-
.on( 'resize'+this.s.namespace, function () {
|
219 |
-
that.s.position.windowHeight = $(window).height();
|
220 |
-
that.update();
|
221 |
-
} );
|
222 |
-
|
223 |
-
var autoHeader = $('.fh-fixedHeader');
|
224 |
-
if ( ! this.c.headerOffset && autoHeader.length ) {
|
225 |
-
this.c.headerOffset = autoHeader.outerHeight();
|
226 |
-
}
|
227 |
-
|
228 |
-
var autoFooter = $('.fh-fixedFooter');
|
229 |
-
if ( ! this.c.footerOffset && autoFooter.length ) {
|
230 |
-
this.c.footerOffset = autoFooter.outerHeight();
|
231 |
-
}
|
232 |
-
|
233 |
-
dt.on( 'column-reorder.dt.dtfc column-visibility.dt.dtfc draw.dt.dtfc column-sizing.dt.dtfc', function () {
|
234 |
-
that.update();
|
235 |
-
} );
|
236 |
-
|
237 |
-
dt.on( 'destroy.dtfc', function () {
|
238 |
-
dt.off( '.dtfc' );
|
239 |
-
$(window).off( that.s.namespace );
|
240 |
-
} );
|
241 |
-
|
242 |
-
this._positions();
|
243 |
-
this._scroll();
|
244 |
-
},
|
245 |
-
|
246 |
-
|
247 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
248 |
-
* Private methods
|
249 |
-
*/
|
250 |
-
|
251 |
-
/**
|
252 |
-
* Clone a fixed item to act as a place holder for the original element
|
253 |
-
* which is moved into a clone of the table element, and moved around the
|
254 |
-
* document to give the fixed effect.
|
255 |
-
*
|
256 |
-
* @param {string} item 'header' or 'footer'
|
257 |
-
* @param {boolean} force Force the clone to happen, or allow automatic
|
258 |
-
* decision (reuse existing if available)
|
259 |
-
* @private
|
260 |
-
*/
|
261 |
-
_clone: function ( item, force )
|
262 |
-
{
|
263 |
-
var dt = this.s.dt;
|
264 |
-
var itemDom = this.dom[ item ];
|
265 |
-
var itemElement = item === 'header' ?
|
266 |
-
this.dom.thead :
|
267 |
-
this.dom.tfoot;
|
268 |
-
|
269 |
-
if ( ! force && itemDom.floating ) {
|
270 |
-
// existing floating element - reuse it
|
271 |
-
itemDom.floating.removeClass( 'fixedHeader-floating fixedHeader-locked' );
|
272 |
-
}
|
273 |
-
else {
|
274 |
-
if ( itemDom.floating ) {
|
275 |
-
itemDom.placeholder.remove();
|
276 |
-
this._unsize( item );
|
277 |
-
itemDom.floating.children().detach();
|
278 |
-
itemDom.floating.remove();
|
279 |
-
}
|
280 |
-
|
281 |
-
itemDom.floating = $( dt.table().node().cloneNode( false ) )
|
282 |
-
.css( 'table-layout', 'fixed' )
|
283 |
-
.removeAttr( 'id' )
|
284 |
-
.append( itemElement )
|
285 |
-
.appendTo( 'body' );
|
286 |
-
|
287 |
-
// Insert a fake thead/tfoot into the DataTable to stop it jumping around
|
288 |
-
itemDom.placeholder = itemElement.clone( false );
|
289 |
-
itemDom.host.prepend( itemDom.placeholder );
|
290 |
-
|
291 |
-
// Clone widths
|
292 |
-
this._matchWidths( itemDom.placeholder, itemDom.floating );
|
293 |
-
}
|
294 |
-
},
|
295 |
-
|
296 |
-
/**
|
297 |
-
* Copy widths from the cells in one element to another. This is required
|
298 |
-
* for the footer as the footer in the main table takes its sizes from the
|
299 |
-
* header columns. That isn't present in the footer so to have it still
|
300 |
-
* align correctly, the sizes need to be copied over. It is also required
|
301 |
-
* for the header when auto width is not enabled
|
302 |
-
*
|
303 |
-
* @param {jQuery} from Copy widths from
|
304 |
-
* @param {jQuery} to Copy widths to
|
305 |
-
* @private
|
306 |
-
*/
|
307 |
-
_matchWidths: function ( from, to ) {
|
308 |
-
var get = function ( name ) {
|
309 |
-
return $(name, from)
|
310 |
-
.map( function () {
|
311 |
-
return $(this).width();
|
312 |
-
} ).toArray();
|
313 |
-
};
|
314 |
-
|
315 |
-
var set = function ( name, toWidths ) {
|
316 |
-
$(name, to).each( function ( i ) {
|
317 |
-
$(this).css( {
|
318 |
-
width: toWidths[i],
|
319 |
-
minWidth: toWidths[i]
|
320 |
-
} );
|
321 |
-
} );
|
322 |
-
};
|
323 |
-
|
324 |
-
var thWidths = get( 'th' );
|
325 |
-
var tdWidths = get( 'td' );
|
326 |
-
|
327 |
-
set( 'th', thWidths );
|
328 |
-
set( 'td', tdWidths );
|
329 |
-
},
|
330 |
-
|
331 |
-
/**
|
332 |
-
* Remove assigned widths from the cells in an element. This is required
|
333 |
-
* when inserting the footer back into the main table so the size is defined
|
334 |
-
* by the header columns and also when auto width is disabled in the
|
335 |
-
* DataTable.
|
336 |
-
*
|
337 |
-
* @param {string} item The `header` or `footer`
|
338 |
-
* @private
|
339 |
-
*/
|
340 |
-
_unsize: function ( item ) {
|
341 |
-
var el = this.dom[ item ].floating;
|
342 |
-
|
343 |
-
if ( el && (item === 'footer' || (item === 'header' && ! this.s.autoWidth)) ) {
|
344 |
-
$('th, td', el).css( {
|
345 |
-
width: '',
|
346 |
-
minWidth: ''
|
347 |
-
} );
|
348 |
-
}
|
349 |
-
else if ( el && item === 'header' ) {
|
350 |
-
$('th, td', el).css( 'min-width', '' );
|
351 |
-
}
|
352 |
-
},
|
353 |
-
|
354 |
-
/**
|
355 |
-
* Reposition the floating elements to take account of horizontal page
|
356 |
-
* scroll
|
357 |
-
*
|
358 |
-
* @param {string} item The `header` or `footer`
|
359 |
-
* @param {int} scrollLeft Document scrollLeft
|
360 |
-
* @private
|
361 |
-
*/
|
362 |
-
_horizontal: function ( item, scrollLeft )
|
363 |
-
{
|
364 |
-
var itemDom = this.dom[ item ];
|
365 |
-
var position = this.s.position;
|
366 |
-
var lastScrollLeft = this.s.scrollLeft;
|
367 |
-
|
368 |
-
if ( itemDom.floating && lastScrollLeft[ item ] !== scrollLeft ) {
|
369 |
-
itemDom.floating.css( 'left', position.left - scrollLeft );
|
370 |
-
|
371 |
-
lastScrollLeft[ item ] = scrollLeft;
|
372 |
-
}
|
373 |
-
},
|
374 |
-
|
375 |
-
/**
|
376 |
-
* Change from one display mode to another. Each fixed item can be in one
|
377 |
-
* of:
|
378 |
-
*
|
379 |
-
* * `in-place` - In the main DataTable
|
380 |
-
* * `in` - Floating over the DataTable
|
381 |
-
* * `below` - (Header only) Fixed to the bottom of the table body
|
382 |
-
* * `above` - (Footer only) Fixed to the top of the table body
|
383 |
-
*
|
384 |
-
* @param {string} mode Mode that the item should be shown in
|
385 |
-
* @param {string} item 'header' or 'footer'
|
386 |
-
* @param {boolean} forceChange Force a redraw of the mode, even if already
|
387 |
-
* in that mode.
|
388 |
-
* @private
|
389 |
-
*/
|
390 |
-
_modeChange: function ( mode, item, forceChange )
|
391 |
-
{
|
392 |
-
var dt = this.s.dt;
|
393 |
-
var itemDom = this.dom[ item ];
|
394 |
-
var position = this.s.position;
|
395 |
-
|
396 |
-
// Record focus. Browser's will cause input elements to loose focus if
|
397 |
-
// they are inserted else where in the doc
|
398 |
-
var tablePart = this.dom[ item==='footer' ? 'tfoot' : 'thead' ];
|
399 |
-
var focus = $.contains( tablePart[0], document.activeElement ) ?
|
400 |
-
document.activeElement :
|
401 |
-
null;
|
402 |
-
|
403 |
-
if ( mode === 'in-place' ) {
|
404 |
-
// Insert the header back into the table's real header
|
405 |
-
if ( itemDom.placeholder ) {
|
406 |
-
itemDom.placeholder.remove();
|
407 |
-
itemDom.placeholder = null;
|
408 |
-
}
|
409 |
-
|
410 |
-
this._unsize( item );
|
411 |
-
|
412 |
-
if ( item === 'header' ) {
|
413 |
-
itemDom.host.prepend( this.dom.thead );
|
414 |
-
}
|
415 |
-
else {
|
416 |
-
itemDom.host.append( this.dom.tfoot );
|
417 |
-
}
|
418 |
-
|
419 |
-
if ( itemDom.floating ) {
|
420 |
-
itemDom.floating.remove();
|
421 |
-
itemDom.floating = null;
|
422 |
-
}
|
423 |
-
}
|
424 |
-
else if ( mode === 'in' ) {
|
425 |
-
// Remove the header from the read header and insert into a fixed
|
426 |
-
// positioned floating table clone
|
427 |
-
this._clone( item, forceChange );
|
428 |
-
|
429 |
-
itemDom.floating
|
430 |
-
.addClass( 'fixedHeader-floating' )
|
431 |
-
.css( item === 'header' ? 'top' : 'bottom', this.c[item+'Offset'] )
|
432 |
-
.css( 'left', position.left+'px' )
|
433 |
-
.css( 'width', position.width+'px' );
|
434 |
-
|
435 |
-
if ( item === 'footer' ) {
|
436 |
-
itemDom.floating.css( 'top', '' );
|
437 |
-
}
|
438 |
-
}
|
439 |
-
else if ( mode === 'below' ) { // only used for the header
|
440 |
-
// Fix the position of the floating header at base of the table body
|
441 |
-
this._clone( item, forceChange );
|
442 |
-
|
443 |
-
itemDom.floating
|
444 |
-
.addClass( 'fixedHeader-locked' )
|
445 |
-
.css( 'top', position.tfootTop - position.theadHeight )
|
446 |
-
.css( 'left', position.left+'px' )
|
447 |
-
.css( 'width', position.width+'px' );
|
448 |
-
}
|
449 |
-
else if ( mode === 'above' ) { // only used for the footer
|
450 |
-
// Fix the position of the floating footer at top of the table body
|
451 |
-
this._clone( item, forceChange );
|
452 |
-
|
453 |
-
itemDom.floating
|
454 |
-
.addClass( 'fixedHeader-locked' )
|
455 |
-
.css( 'top', position.tbodyTop )
|
456 |
-
.css( 'left', position.left+'px' )
|
457 |
-
.css( 'width', position.width+'px' );
|
458 |
-
}
|
459 |
-
|
460 |
-
// Restore focus if it was lost
|
461 |
-
if ( focus && focus !== document.activeElement ) {
|
462 |
-
focus.focus();
|
463 |
-
}
|
464 |
-
|
465 |
-
this.s.scrollLeft.header = -1;
|
466 |
-
this.s.scrollLeft.footer = -1;
|
467 |
-
this.s[item+'Mode'] = mode;
|
468 |
-
},
|
469 |
-
|
470 |
-
/**
|
471 |
-
* Cache the positional information that is required for the mode
|
472 |
-
* calculations that FixedHeader performs.
|
473 |
-
*
|
474 |
-
* @private
|
475 |
-
*/
|
476 |
-
_positions: function ()
|
477 |
-
{
|
478 |
-
var dt = this.s.dt;
|
479 |
-
var table = dt.table();
|
480 |
-
var position = this.s.position;
|
481 |
-
var dom = this.dom;
|
482 |
-
var tableNode = $(table.node());
|
483 |
-
|
484 |
-
// Need to use the header and footer that are in the main table,
|
485 |
-
// regardless of if they are clones, since they hold the positions we
|
486 |
-
// want to measure from
|
487 |
-
var thead = tableNode.children('thead');
|
488 |
-
var tfoot = tableNode.children('tfoot');
|
489 |
-
var tbody = dom.tbody;
|
490 |
-
|
491 |
-
position.visible = tableNode.is(':visible');
|
492 |
-
position.width = tableNode.outerWidth();
|
493 |
-
position.left = tableNode.offset().left;
|
494 |
-
position.theadTop = thead.offset().top;
|
495 |
-
position.tbodyTop = tbody.offset().top;
|
496 |
-
position.theadHeight = position.tbodyTop - position.theadTop;
|
497 |
-
|
498 |
-
if ( tfoot.length ) {
|
499 |
-
position.tfootTop = tfoot.offset().top;
|
500 |
-
position.tfootBottom = position.tfootTop + tfoot.outerHeight();
|
501 |
-
position.tfootHeight = position.tfootBottom - position.tfootTop;
|
502 |
-
}
|
503 |
-
else {
|
504 |
-
position.tfootTop = position.tbodyTop + tbody.outerHeight();
|
505 |
-
position.tfootBottom = position.tfootTop;
|
506 |
-
position.tfootHeight = position.tfootTop;
|
507 |
-
}
|
508 |
-
},
|
509 |
-
|
510 |
-
|
511 |
-
/**
|
512 |
-
* Mode calculation - determine what mode the fixed items should be placed
|
513 |
-
* into.
|
514 |
-
*
|
515 |
-
* @param {boolean} forceChange Force a redraw of the mode, even if already
|
516 |
-
* in that mode.
|
517 |
-
* @private
|
518 |
-
*/
|
519 |
-
_scroll: function ( forceChange )
|
520 |
-
{
|
521 |
-
var windowTop = $(document).scrollTop();
|
522 |
-
var windowLeft = $(document).scrollLeft();
|
523 |
-
var position = this.s.position;
|
524 |
-
var headerMode, footerMode;
|
525 |
-
|
526 |
-
if ( ! this.s.enable ) {
|
527 |
-
return;
|
528 |
-
}
|
529 |
-
|
530 |
-
if ( this.c.header ) {
|
531 |
-
if ( ! position.visible || windowTop <= position.theadTop - this.c.headerOffset ) {
|
532 |
-
headerMode = 'in-place';
|
533 |
-
}
|
534 |
-
else if ( windowTop <= position.tfootTop - position.theadHeight - this.c.headerOffset ) {
|
535 |
-
headerMode = 'in';
|
536 |
-
}
|
537 |
-
else {
|
538 |
-
headerMode = 'below';
|
539 |
-
}
|
540 |
-
|
541 |
-
if ( forceChange || headerMode !== this.s.headerMode ) {
|
542 |
-
this._modeChange( headerMode, 'header', forceChange );
|
543 |
-
}
|
544 |
-
|
545 |
-
this._horizontal( 'header', windowLeft );
|
546 |
-
}
|
547 |
-
|
548 |
-
if ( this.c.footer && this.dom.tfoot.length ) {
|
549 |
-
if ( ! position.visible || windowTop + position.windowHeight >= position.tfootBottom + this.c.footerOffset ) {
|
550 |
-
footerMode = 'in-place';
|
551 |
-
}
|
552 |
-
else if ( position.windowHeight + windowTop > position.tbodyTop + position.tfootHeight + this.c.footerOffset ) {
|
553 |
-
footerMode = 'in';
|
554 |
-
}
|
555 |
-
else {
|
556 |
-
footerMode = 'above';
|
557 |
-
}
|
558 |
-
|
559 |
-
if ( forceChange || footerMode !== this.s.footerMode ) {
|
560 |
-
this._modeChange( footerMode, 'footer', forceChange );
|
561 |
-
}
|
562 |
-
|
563 |
-
this._horizontal( 'footer', windowLeft );
|
564 |
-
}
|
565 |
-
}
|
566 |
-
} );
|
567 |
-
|
568 |
-
|
569 |
-
/**
|
570 |
-
* Version
|
571 |
-
* @type {String}
|
572 |
-
* @static
|
573 |
-
*/
|
574 |
-
FixedHeader.version = "3.1.2";
|
575 |
-
|
576 |
-
/**
|
577 |
-
* Defaults
|
578 |
-
* @type {Object}
|
579 |
-
* @static
|
580 |
-
*/
|
581 |
-
FixedHeader.defaults = {
|
582 |
-
header: true,
|
583 |
-
footer: false,
|
584 |
-
headerOffset: 0,
|
585 |
-
footerOffset: 0
|
586 |
-
};
|
587 |
-
|
588 |
-
|
589 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
590 |
-
* DataTables interfaces
|
591 |
-
*/
|
592 |
-
|
593 |
-
// Attach for constructor access
|
594 |
-
$.fn.dataTable.FixedHeader = FixedHeader;
|
595 |
-
$.fn.DataTable.FixedHeader = FixedHeader;
|
596 |
-
|
597 |
-
|
598 |
-
// DataTables creation - check if the FixedHeader option has been defined on the
|
599 |
-
// table and if so, initialise
|
600 |
-
$(document).on( 'init.dt.dtfh', function (e, settings, json) {
|
601 |
-
if ( e.namespace !== 'dt' ) {
|
602 |
-
return;
|
603 |
-
}
|
604 |
-
|
605 |
-
var init = settings.oInit.fixedHeader;
|
606 |
-
var defaults = DataTable.defaults.fixedHeader;
|
607 |
-
|
608 |
-
if ( (init || defaults) && ! settings._fixedHeader ) {
|
609 |
-
var opts = $.extend( {}, defaults, init );
|
610 |
-
|
611 |
-
if ( init !== false ) {
|
612 |
-
new FixedHeader( settings, opts );
|
613 |
-
}
|
614 |
-
}
|
615 |
-
} );
|
616 |
-
|
617 |
-
// DataTables API methods
|
618 |
-
DataTable.Api.register( 'fixedHeader()', function () {} );
|
619 |
-
|
620 |
-
DataTable.Api.register( 'fixedHeader.adjust()', function () {
|
621 |
-
return this.iterator( 'table', function ( ctx ) {
|
622 |
-
var fh = ctx._fixedHeader;
|
623 |
-
|
624 |
-
if ( fh ) {
|
625 |
-
fh.update();
|
626 |
-
}
|
627 |
-
} );
|
628 |
-
} );
|
629 |
-
|
630 |
-
DataTable.Api.register( 'fixedHeader.enable()', function ( flag ) {
|
631 |
-
return this.iterator( 'table', function ( ctx ) {
|
632 |
-
var fh = ctx._fixedHeader;
|
633 |
-
|
634 |
-
if ( fh ) {
|
635 |
-
fh.enable( flag !== undefined ? flag : true );
|
636 |
-
}
|
637 |
-
} );
|
638 |
-
} );
|
639 |
-
|
640 |
-
DataTable.Api.register( 'fixedHeader.disable()', function ( ) {
|
641 |
-
return this.iterator( 'table', function ( ctx ) {
|
642 |
-
var fh = ctx._fixedHeader;
|
643 |
-
|
644 |
-
if ( fh ) {
|
645 |
-
fh.enable( false );
|
646 |
-
}
|
647 |
-
} );
|
648 |
-
} );
|
649 |
-
|
650 |
-
$.each( ['header', 'footer'], function ( i, el ) {
|
651 |
-
DataTable.Api.register( 'fixedHeader.'+el+'Offset()', function ( offset ) {
|
652 |
-
var ctx = this.context;
|
653 |
-
|
654 |
-
if ( offset === undefined ) {
|
655 |
-
return ctx.length && ctx[0]._fixedHeader ?
|
656 |
-
ctx[0]._fixedHeader[el +'Offset']() :
|
657 |
-
undefined;
|
658 |
-
}
|
659 |
-
|
660 |
-
return this.iterator( 'table', function ( ctx ) {
|
661 |
-
var fh = ctx._fixedHeader;
|
662 |
-
|
663 |
-
if ( fh ) {
|
664 |
-
fh[ el +'Offset' ]( offset );
|
665 |
-
}
|
666 |
-
} );
|
667 |
-
} );
|
668 |
-
} );
|
669 |
-
|
670 |
-
|
671 |
-
return FixedHeader;
|
672 |
-
}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/FixedHeader/js/dataTables.fixedHeader.min.js
DELETED
@@ -1,17 +0,0 @@
|
|
1 |
-
/*!
|
2 |
-
FixedHeader 3.1.2
|
3 |
-
©2009-2016 SpryMedia Ltd - datatables.net/license
|
4 |
-
*/
|
5 |
-
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(g){return d(g,window,document)}):"object"===typeof exports?module.exports=function(g,h){g||(g=window);if(!h||!h.fn.dataTable)h=require("datatables.net")(g,h).$;return d(h,g,g.document)}:d(jQuery,window,document)})(function(d,g,h,k){var j=d.fn.dataTable,l=0,i=function(b,a){if(!(this instanceof i))throw"FixedHeader must be initialised with the 'new' keyword.";!0===a&&(a={});b=new j.Api(b);this.c=d.extend(!0,
|
6 |
-
{},i.defaults,a);this.s={dt:b,position:{theadTop:0,tbodyTop:0,tfootTop:0,tfootBottom:0,width:0,left:0,tfootHeight:0,theadHeight:0,windowHeight:d(g).height(),visible:!0},headerMode:null,footerMode:null,autoWidth:b.settings()[0].oFeatures.bAutoWidth,namespace:".dtfc"+l++,scrollLeft:{header:-1,footer:-1},enable:!0};this.dom={floatingHeader:null,thead:d(b.table().header()),tbody:d(b.table().body()),tfoot:d(b.table().footer()),header:{host:null,floating:null,placeholder:null},footer:{host:null,floating:null,
|
7 |
-
placeholder:null}};this.dom.header.host=this.dom.thead.parent();this.dom.footer.host=this.dom.tfoot.parent();var e=b.settings()[0];if(e._fixedHeader)throw"FixedHeader already initialised on table "+e.nTable.id;e._fixedHeader=this;this._constructor()};d.extend(i.prototype,{enable:function(b){this.s.enable=b;this.c.header&&this._modeChange("in-place","header",!0);this.c.footer&&this.dom.tfoot.length&&this._modeChange("in-place","footer",!0);this.update()},headerOffset:function(b){b!==k&&(this.c.headerOffset=
|
8 |
-
b,this.update());return this.c.headerOffset},footerOffset:function(b){b!==k&&(this.c.footerOffset=b,this.update());return this.c.footerOffset},update:function(){this._positions();this._scroll(!0)},_constructor:function(){var b=this,a=this.s.dt;d(g).on("scroll"+this.s.namespace,function(){b._scroll()}).on("resize"+this.s.namespace,function(){b.s.position.windowHeight=d(g).height();b.update()});var e=d(".fh-fixedHeader");!this.c.headerOffset&&e.length&&(this.c.headerOffset=e.outerHeight());e=d(".fh-fixedFooter");
|
9 |
-
!this.c.footerOffset&&e.length&&(this.c.footerOffset=e.outerHeight());a.on("column-reorder.dt.dtfc column-visibility.dt.dtfc draw.dt.dtfc column-sizing.dt.dtfc",function(){b.update()});a.on("destroy.dtfc",function(){a.off(".dtfc");d(g).off(b.s.namespace)});this._positions();this._scroll()},_clone:function(b,a){var e=this.s.dt,c=this.dom[b],f="header"===b?this.dom.thead:this.dom.tfoot;!a&&c.floating?c.floating.removeClass("fixedHeader-floating fixedHeader-locked"):(c.floating&&(c.placeholder.remove(),
|
10 |
-
this._unsize(b),c.floating.children().detach(),c.floating.remove()),c.floating=d(e.table().node().cloneNode(!1)).css("table-layout","fixed").removeAttr("id").append(f).appendTo("body"),c.placeholder=f.clone(!1),c.host.prepend(c.placeholder),this._matchWidths(c.placeholder,c.floating))},_matchWidths:function(b,a){var e=function(a){return d(a,b).map(function(){return d(this).width()}).toArray()},c=function(b,c){d(b,a).each(function(a){d(this).css({width:c[a],minWidth:c[a]})})},f=e("th"),e=e("td");c("th",
|
11 |
-
f);c("td",e)},_unsize:function(b){var a=this.dom[b].floating;a&&("footer"===b||"header"===b&&!this.s.autoWidth)?d("th, td",a).css({width:"",minWidth:""}):a&&"header"===b&&d("th, td",a).css("min-width","")},_horizontal:function(b,a){var e=this.dom[b],c=this.s.position,d=this.s.scrollLeft;e.floating&&d[b]!==a&&(e.floating.css("left",c.left-a),d[b]=a)},_modeChange:function(b,a,e){var c=this.dom[a],f=this.s.position,g=d.contains(this.dom["footer"===a?"tfoot":"thead"][0],h.activeElement)?h.activeElement:
|
12 |
-
null;if("in-place"===b){if(c.placeholder&&(c.placeholder.remove(),c.placeholder=null),this._unsize(a),"header"===a?c.host.prepend(this.dom.thead):c.host.append(this.dom.tfoot),c.floating)c.floating.remove(),c.floating=null}else"in"===b?(this._clone(a,e),c.floating.addClass("fixedHeader-floating").css("header"===a?"top":"bottom",this.c[a+"Offset"]).css("left",f.left+"px").css("width",f.width+"px"),"footer"===a&&c.floating.css("top","")):"below"===b?(this._clone(a,e),c.floating.addClass("fixedHeader-locked").css("top",
|
13 |
-
f.tfootTop-f.theadHeight).css("left",f.left+"px").css("width",f.width+"px")):"above"===b&&(this._clone(a,e),c.floating.addClass("fixedHeader-locked").css("top",f.tbodyTop).css("left",f.left+"px").css("width",f.width+"px"));g&&g!==h.activeElement&&g.focus();this.s.scrollLeft.header=-1;this.s.scrollLeft.footer=-1;this.s[a+"Mode"]=b},_positions:function(){var b=this.s.dt.table(),a=this.s.position,e=this.dom,b=d(b.node()),c=b.children("thead"),f=b.children("tfoot"),e=e.tbody;a.visible=b.is(":visible");
|
14 |
-
a.width=b.outerWidth();a.left=b.offset().left;a.theadTop=c.offset().top;a.tbodyTop=e.offset().top;a.theadHeight=a.tbodyTop-a.theadTop;f.length?(a.tfootTop=f.offset().top,a.tfootBottom=a.tfootTop+f.outerHeight(),a.tfootHeight=a.tfootBottom-a.tfootTop):(a.tfootTop=a.tbodyTop+e.outerHeight(),a.tfootBottom=a.tfootTop,a.tfootHeight=a.tfootTop)},_scroll:function(b){var a=d(h).scrollTop(),e=d(h).scrollLeft(),c=this.s.position,f;if(this.s.enable&&(this.c.header&&(f=!c.visible||a<=c.theadTop-this.c.headerOffset?
|
15 |
-
"in-place":a<=c.tfootTop-c.theadHeight-this.c.headerOffset?"in":"below",(b||f!==this.s.headerMode)&&this._modeChange(f,"header",b),this._horizontal("header",e)),this.c.footer&&this.dom.tfoot.length))a=!c.visible||a+c.windowHeight>=c.tfootBottom+this.c.footerOffset?"in-place":c.windowHeight+a>c.tbodyTop+c.tfootHeight+this.c.footerOffset?"in":"above",(b||a!==this.s.footerMode)&&this._modeChange(a,"footer",b),this._horizontal("footer",e)}});i.version="3.1.2";i.defaults={header:!0,footer:!1,headerOffset:0,
|
16 |
-
footerOffset:0};d.fn.dataTable.FixedHeader=i;d.fn.DataTable.FixedHeader=i;d(h).on("init.dt.dtfh",function(b,a){if("dt"===b.namespace){var e=a.oInit.fixedHeader,c=j.defaults.fixedHeader;if((e||c)&&!a._fixedHeader)c=d.extend({},c,e),!1!==e&&new i(a,c)}});j.Api.register("fixedHeader()",function(){});j.Api.register("fixedHeader.adjust()",function(){return this.iterator("table",function(b){(b=b._fixedHeader)&&b.update()})});j.Api.register("fixedHeader.enable()",function(b){return this.iterator("table",
|
17 |
-
function(a){(a=a._fixedHeader)&&a.enable(b!==k?b:!0)})});j.Api.register("fixedHeader.disable()",function(){return this.iterator("table",function(b){(b=b._fixedHeader)&&b.enable(!1)})});d.each(["header","footer"],function(b,a){j.Api.register("fixedHeader."+a+"Offset()",function(b){var c=this.context;return b===k?c.length&&c[0]._fixedHeader?c[0]._fixedHeader[a+"Offset"]():k:this.iterator("table",function(c){if(c=c._fixedHeader)c[a+"Offset"](b)})})});return i});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Responsive/css/responsive.dataTables.css
DELETED
@@ -1,178 +0,0 @@
|
|
1 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td.child,
|
2 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > th.child,
|
3 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dataTables_empty {
|
4 |
-
cursor: default !important;
|
5 |
-
}
|
6 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td.child:before,
|
7 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > th.child:before,
|
8 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dataTables_empty:before {
|
9 |
-
display: none !important;
|
10 |
-
}
|
11 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td:first-child,
|
12 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > th:first-child {
|
13 |
-
position: relative;
|
14 |
-
padding-left: 30px;
|
15 |
-
cursor: pointer;
|
16 |
-
}
|
17 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > td:first-child:before,
|
18 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr > th:first-child:before {
|
19 |
-
top: 9px;
|
20 |
-
left: 4px;
|
21 |
-
height: 14px;
|
22 |
-
width: 14px;
|
23 |
-
display: block;
|
24 |
-
position: absolute;
|
25 |
-
color: white;
|
26 |
-
border: 2px solid white;
|
27 |
-
border-radius: 14px;
|
28 |
-
box-shadow: 0 0 3px #444;
|
29 |
-
box-sizing: content-box;
|
30 |
-
text-align: center;
|
31 |
-
font-family: 'Courier New', Courier, monospace;
|
32 |
-
line-height: 14px;
|
33 |
-
content: '+';
|
34 |
-
background-color: #31b131;
|
35 |
-
}
|
36 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td:first-child:before,
|
37 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > th:first-child:before {
|
38 |
-
content: '-';
|
39 |
-
background-color: #d33333;
|
40 |
-
}
|
41 |
-
table.dataTable.dtr-inline.collapsed > tbody > tr.child td:before {
|
42 |
-
display: none;
|
43 |
-
}
|
44 |
-
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > td:first-child,
|
45 |
-
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > th:first-child {
|
46 |
-
padding-left: 27px;
|
47 |
-
}
|
48 |
-
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > td:first-child:before,
|
49 |
-
table.dataTable.dtr-inline.collapsed.compact > tbody > tr > th:first-child:before {
|
50 |
-
top: 5px;
|
51 |
-
left: 4px;
|
52 |
-
height: 14px;
|
53 |
-
width: 14px;
|
54 |
-
border-radius: 14px;
|
55 |
-
line-height: 14px;
|
56 |
-
text-indent: 3px;
|
57 |
-
}
|
58 |
-
table.dataTable.dtr-column > tbody > tr > td.control,
|
59 |
-
table.dataTable.dtr-column > tbody > tr > th.control {
|
60 |
-
position: relative;
|
61 |
-
cursor: pointer;
|
62 |
-
}
|
63 |
-
table.dataTable.dtr-column > tbody > tr > td.control:before,
|
64 |
-
table.dataTable.dtr-column > tbody > tr > th.control:before {
|
65 |
-
top: 50%;
|
66 |
-
left: 50%;
|
67 |
-
height: 16px;
|
68 |
-
width: 16px;
|
69 |
-
margin-top: -10px;
|
70 |
-
margin-left: -10px;
|
71 |
-
display: block;
|
72 |
-
position: absolute;
|
73 |
-
color: white;
|
74 |
-
border: 2px solid white;
|
75 |
-
border-radius: 14px;
|
76 |
-
box-shadow: 0 0 3px #444;
|
77 |
-
box-sizing: content-box;
|
78 |
-
text-align: center;
|
79 |
-
font-family: 'Courier New', Courier, monospace;
|
80 |
-
line-height: 14px;
|
81 |
-
content: '+';
|
82 |
-
background-color: #31b131;
|
83 |
-
}
|
84 |
-
table.dataTable.dtr-column > tbody > tr.parent td.control:before,
|
85 |
-
table.dataTable.dtr-column > tbody > tr.parent th.control:before {
|
86 |
-
content: '-';
|
87 |
-
background-color: #d33333;
|
88 |
-
}
|
89 |
-
table.dataTable > tbody > tr.child {
|
90 |
-
padding: 0.5em 1em;
|
91 |
-
}
|
92 |
-
table.dataTable > tbody > tr.child:hover {
|
93 |
-
background: transparent !important;
|
94 |
-
}
|
95 |
-
table.dataTable > tbody > tr.child ul {
|
96 |
-
display: inline-block;
|
97 |
-
list-style-type: none;
|
98 |
-
margin: 0;
|
99 |
-
padding: 0;
|
100 |
-
}
|
101 |
-
table.dataTable > tbody > tr.child ul li {
|
102 |
-
border-bottom: 1px solid #efefef;
|
103 |
-
padding: 0.5em 0;
|
104 |
-
}
|
105 |
-
table.dataTable > tbody > tr.child ul li:first-child {
|
106 |
-
padding-top: 0;
|
107 |
-
}
|
108 |
-
table.dataTable > tbody > tr.child ul li:last-child {
|
109 |
-
border-bottom: none;
|
110 |
-
}
|
111 |
-
table.dataTable > tbody > tr.child span.dtr-title {
|
112 |
-
display: inline-block;
|
113 |
-
min-width: 75px;
|
114 |
-
font-weight: bold;
|
115 |
-
}
|
116 |
-
|
117 |
-
div.dtr-modal {
|
118 |
-
position: fixed;
|
119 |
-
box-sizing: border-box;
|
120 |
-
top: 0;
|
121 |
-
left: 0;
|
122 |
-
height: 100%;
|
123 |
-
width: 100%;
|
124 |
-
z-index: 100;
|
125 |
-
padding: 10em 1em;
|
126 |
-
}
|
127 |
-
div.dtr-modal div.dtr-modal-display {
|
128 |
-
position: absolute;
|
129 |
-
top: 0;
|
130 |
-
left: 0;
|
131 |
-
bottom: 0;
|
132 |
-
right: 0;
|
133 |
-
width: 50%;
|
134 |
-
height: 50%;
|
135 |
-
overflow: auto;
|
136 |
-
margin: auto;
|
137 |
-
z-index: 102;
|
138 |
-
overflow: auto;
|
139 |
-
background-color: #f5f5f7;
|
140 |
-
border: 1px solid black;
|
141 |
-
border-radius: 0.5em;
|
142 |
-
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
|
143 |
-
}
|
144 |
-
div.dtr-modal div.dtr-modal-content {
|
145 |
-
position: relative;
|
146 |
-
padding: 1em;
|
147 |
-
}
|
148 |
-
div.dtr-modal div.dtr-modal-close {
|
149 |
-
position: absolute;
|
150 |
-
top: 6px;
|
151 |
-
right: 6px;
|
152 |
-
width: 22px;
|
153 |
-
height: 22px;
|
154 |
-
border: 1px solid #eaeaea;
|
155 |
-
background-color: #f9f9f9;
|
156 |
-
text-align: center;
|
157 |
-
border-radius: 3px;
|
158 |
-
cursor: pointer;
|
159 |
-
z-index: 12;
|
160 |
-
}
|
161 |
-
div.dtr-modal div.dtr-modal-close:hover {
|
162 |
-
background-color: #eaeaea;
|
163 |
-
}
|
164 |
-
div.dtr-modal div.dtr-modal-background {
|
165 |
-
position: fixed;
|
166 |
-
top: 0;
|
167 |
-
left: 0;
|
168 |
-
right: 0;
|
169 |
-
bottom: 0;
|
170 |
-
z-index: 101;
|
171 |
-
background: rgba(0, 0, 0, 0.6);
|
172 |
-
}
|
173 |
-
|
174 |
-
@media screen and (max-width: 767px) {
|
175 |
-
div.dtr-modal div.dtr-modal-display {
|
176 |
-
width: 95%;
|
177 |
-
}
|
178 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Responsive/css/responsive.dataTables.min.css
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
table.dataTable.dtr-inline.collapsed>tbody>tr>td.child,table.dataTable.dtr-inline.collapsed>tbody>tr>th.child,table.dataTable.dtr-inline.collapsed>tbody>tr>td.dataTables_empty{cursor:default !important}table.dataTable.dtr-inline.collapsed>tbody>tr>td.child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>th.child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>td.dataTables_empty:before{display:none !important}table.dataTable.dtr-inline.collapsed>tbody>tr>td:first-child,table.dataTable.dtr-inline.collapsed>tbody>tr>th:first-child{position:relative;padding-left:30px;cursor:pointer}table.dataTable.dtr-inline.collapsed>tbody>tr>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>th:first-child:before{top:9px;left:4px;height:14px;width:14px;display:block;position:absolute;color:white;border:2px solid white;border-radius:14px;box-shadow:0 0 3px #444;box-sizing:content-box;text-align:center;font-family:'Courier New', Courier, monospace;line-height:14px;content:'+';background-color:#31b131}table.dataTable.dtr-inline.collapsed>tbody>tr.parent>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr.parent>th:first-child:before{content:'-';background-color:#d33333}table.dataTable.dtr-inline.collapsed>tbody>tr.child td:before{display:none}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child{padding-left:27px}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child:before,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child:before{top:5px;left:4px;height:14px;width:14px;border-radius:14px;line-height:14px;text-indent:3px}table.dataTable.dtr-column>tbody>tr>td.control,table.dataTable.dtr-column>tbody>tr>th.control{position:relative;cursor:pointer}table.dataTable.dtr-column>tbody>tr>td.control:before,table.dataTable.dtr-column>tbody>tr>th.control:before{top:50%;left:50%;height:16px;width:16px;margin-top:-10px;margin-left:-10px;display:block;position:absolute;color:white;border:2px solid white;border-radius:14px;box-shadow:0 0 3px #444;box-sizing:content-box;text-align:center;font-family:'Courier New', Courier, monospace;line-height:14px;content:'+';background-color:#31b131}table.dataTable.dtr-column>tbody>tr.parent td.control:before,table.dataTable.dtr-column>tbody>tr.parent th.control:before{content:'-';background-color:#d33333}table.dataTable>tbody>tr.child{padding:0.5em 1em}table.dataTable>tbody>tr.child:hover{background:transparent !important}table.dataTable>tbody>tr.child ul{display:inline-block;list-style-type:none;margin:0;padding:0}table.dataTable>tbody>tr.child ul li{border-bottom:1px solid #efefef;padding:0.5em 0}table.dataTable>tbody>tr.child ul li:first-child{padding-top:0}table.dataTable>tbody>tr.child ul li:last-child{border-bottom:none}table.dataTable>tbody>tr.child span.dtr-title{display:inline-block;min-width:75px;font-weight:bold}div.dtr-modal{position:fixed;box-sizing:border-box;top:0;left:0;height:100%;width:100%;z-index:100;padding:10em 1em}div.dtr-modal div.dtr-modal-display{position:absolute;top:0;left:0;bottom:0;right:0;width:50%;height:50%;overflow:auto;margin:auto;z-index:102;overflow:auto;background-color:#f5f5f7;border:1px solid black;border-radius:0.5em;box-shadow:0 12px 30px rgba(0,0,0,0.6)}div.dtr-modal div.dtr-modal-content{position:relative;padding:1em}div.dtr-modal div.dtr-modal-close{position:absolute;top:6px;right:6px;width:22px;height:22px;border:1px solid #eaeaea;background-color:#f9f9f9;text-align:center;border-radius:3px;cursor:pointer;z-index:12}div.dtr-modal div.dtr-modal-close:hover{background-color:#eaeaea}div.dtr-modal div.dtr-modal-background{position:fixed;top:0;left:0;right:0;bottom:0;z-index:101;background:rgba(0,0,0,0.6)}@media screen and (max-width: 767px){div.dtr-modal div.dtr-modal-display{width:95%}}
|
|
common/vendor/datatables/extensions/Responsive/js/dataTables.responsive.js
DELETED
@@ -1,1232 +0,0 @@
|
|
1 |
-
/*! Responsive 2.1.0
|
2 |
-
* 2014-2016 SpryMedia Ltd - datatables.net/license
|
3 |
-
*/
|
4 |
-
|
5 |
-
/**
|
6 |
-
* @summary Responsive
|
7 |
-
* @description Responsive tables plug-in for DataTables
|
8 |
-
* @version 2.1.0
|
9 |
-
* @file dataTables.responsive.js
|
10 |
-
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
11 |
-
* @contact www.sprymedia.co.uk/contact
|
12 |
-
* @copyright Copyright 2014-2016 SpryMedia Ltd.
|
13 |
-
*
|
14 |
-
* This source file is free software, available under the following license:
|
15 |
-
* MIT license - http://datatables.net/license/mit
|
16 |
-
*
|
17 |
-
* This source file is distributed in the hope that it will be useful, but
|
18 |
-
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
19 |
-
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
20 |
-
*
|
21 |
-
* For details please refer to: http://www.datatables.net
|
22 |
-
*/
|
23 |
-
(function( factory ){
|
24 |
-
if ( typeof define === 'function' && define.amd ) {
|
25 |
-
// AMD
|
26 |
-
define( ['jquery', 'datatables.net'], function ( $ ) {
|
27 |
-
return factory( $, window, document );
|
28 |
-
} );
|
29 |
-
}
|
30 |
-
else if ( typeof exports === 'object' ) {
|
31 |
-
// CommonJS
|
32 |
-
module.exports = function (root, $) {
|
33 |
-
if ( ! root ) {
|
34 |
-
root = window;
|
35 |
-
}
|
36 |
-
|
37 |
-
if ( ! $ || ! $.fn.dataTable ) {
|
38 |
-
$ = require('datatables.net')(root, $).$;
|
39 |
-
}
|
40 |
-
|
41 |
-
return factory( $, root, root.document );
|
42 |
-
};
|
43 |
-
}
|
44 |
-
else {
|
45 |
-
// Browser
|
46 |
-
factory( jQuery, window, document );
|
47 |
-
}
|
48 |
-
}(function( $, window, document, undefined ) {
|
49 |
-
'use strict';
|
50 |
-
var DataTable = $.fn.dataTable;
|
51 |
-
|
52 |
-
|
53 |
-
/**
|
54 |
-
* Responsive is a plug-in for the DataTables library that makes use of
|
55 |
-
* DataTables' ability to change the visibility of columns, changing the
|
56 |
-
* visibility of columns so the displayed columns fit into the table container.
|
57 |
-
* The end result is that complex tables will be dynamically adjusted to fit
|
58 |
-
* into the viewport, be it on a desktop, tablet or mobile browser.
|
59 |
-
*
|
60 |
-
* Responsive for DataTables has two modes of operation, which can used
|
61 |
-
* individually or combined:
|
62 |
-
*
|
63 |
-
* * Class name based control - columns assigned class names that match the
|
64 |
-
* breakpoint logic can be shown / hidden as required for each breakpoint.
|
65 |
-
* * Automatic control - columns are automatically hidden when there is no
|
66 |
-
* room left to display them. Columns removed from the right.
|
67 |
-
*
|
68 |
-
* In additional to column visibility control, Responsive also has built into
|
69 |
-
* options to use DataTables' child row display to show / hide the information
|
70 |
-
* from the table that has been hidden. There are also two modes of operation
|
71 |
-
* for this child row display:
|
72 |
-
*
|
73 |
-
* * Inline - when the control element that the user can use to show / hide
|
74 |
-
* child rows is displayed inside the first column of the table.
|
75 |
-
* * Column - where a whole column is dedicated to be the show / hide control.
|
76 |
-
*
|
77 |
-
* Initialisation of Responsive is performed by:
|
78 |
-
*
|
79 |
-
* * Adding the class `responsive` or `dt-responsive` to the table. In this case
|
80 |
-
* Responsive will automatically be initialised with the default configuration
|
81 |
-
* options when the DataTable is created.
|
82 |
-
* * Using the `responsive` option in the DataTables configuration options. This
|
83 |
-
* can also be used to specify the configuration options, or simply set to
|
84 |
-
* `true` to use the defaults.
|
85 |
-
*
|
86 |
-
* @class
|
87 |
-
* @param {object} settings DataTables settings object for the host table
|
88 |
-
* @param {object} [opts] Configuration options
|
89 |
-
* @requires jQuery 1.7+
|
90 |
-
* @requires DataTables 1.10.3+
|
91 |
-
*
|
92 |
-
* @example
|
93 |
-
* $('#example').DataTable( {
|
94 |
-
* responsive: true
|
95 |
-
* } );
|
96 |
-
* } );
|
97 |
-
*/
|
98 |
-
var Responsive = function ( settings, opts ) {
|
99 |
-
// Sanity check that we are using DataTables 1.10 or newer
|
100 |
-
if ( ! DataTable.versionCheck || ! DataTable.versionCheck( '1.10.3' ) ) {
|
101 |
-
throw 'DataTables Responsive requires DataTables 1.10.3 or newer';
|
102 |
-
}
|
103 |
-
|
104 |
-
this.s = {
|
105 |
-
dt: new DataTable.Api( settings ),
|
106 |
-
columns: [],
|
107 |
-
current: []
|
108 |
-
};
|
109 |
-
|
110 |
-
// Check if responsive has already been initialised on this table
|
111 |
-
if ( this.s.dt.settings()[0].responsive ) {
|
112 |
-
return;
|
113 |
-
}
|
114 |
-
|
115 |
-
// details is an object, but for simplicity the user can give it as a string
|
116 |
-
// or a boolean
|
117 |
-
if ( opts && typeof opts.details === 'string' ) {
|
118 |
-
opts.details = { type: opts.details };
|
119 |
-
}
|
120 |
-
else if ( opts && opts.details === false ) {
|
121 |
-
opts.details = { type: false };
|
122 |
-
}
|
123 |
-
else if ( opts && opts.details === true ) {
|
124 |
-
opts.details = { type: 'inline' };
|
125 |
-
}
|
126 |
-
|
127 |
-
this.c = $.extend( true, {}, Responsive.defaults, DataTable.defaults.responsive, opts );
|
128 |
-
settings.responsive = this;
|
129 |
-
this._constructor();
|
130 |
-
};
|
131 |
-
|
132 |
-
$.extend( Responsive.prototype, {
|
133 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
134 |
-
* Constructor
|
135 |
-
*/
|
136 |
-
|
137 |
-
/**
|
138 |
-
* Initialise the Responsive instance
|
139 |
-
*
|
140 |
-
* @private
|
141 |
-
*/
|
142 |
-
_constructor: function ()
|
143 |
-
{
|
144 |
-
var that = this;
|
145 |
-
var dt = this.s.dt;
|
146 |
-
var dtPrivateSettings = dt.settings()[0];
|
147 |
-
var oldWindowWidth = $(window).width();
|
148 |
-
|
149 |
-
dt.settings()[0]._responsive = this;
|
150 |
-
|
151 |
-
// Use DataTables' throttle function to avoid processor thrashing on
|
152 |
-
// resize
|
153 |
-
$(window).on( 'resize.dtr orientationchange.dtr', DataTable.util.throttle( function () {
|
154 |
-
// iOS has a bug whereby resize can fire when only scrolling
|
155 |
-
// See: http://stackoverflow.com/questions/8898412
|
156 |
-
var width = $(window).width();
|
157 |
-
|
158 |
-
if ( width !== oldWindowWidth ) {
|
159 |
-
that._resize();
|
160 |
-
oldWindowWidth = width;
|
161 |
-
}
|
162 |
-
} ) );
|
163 |
-
|
164 |
-
// DataTables doesn't currently trigger an event when a row is added, so
|
165 |
-
// we need to hook into its private API to enforce the hidden rows when
|
166 |
-
// new data is added
|
167 |
-
dtPrivateSettings.oApi._fnCallbackReg( dtPrivateSettings, 'aoRowCreatedCallback', function (tr, data, idx) {
|
168 |
-
if ( $.inArray( false, that.s.current ) !== -1 ) {
|
169 |
-
$('td, th', tr).each( function ( i ) {
|
170 |
-
var idx = dt.column.index( 'toData', i );
|
171 |
-
|
172 |
-
if ( that.s.current[idx] === false ) {
|
173 |
-
$(this).css('display', 'none');
|
174 |
-
}
|
175 |
-
} );
|
176 |
-
}
|
177 |
-
} );
|
178 |
-
|
179 |
-
// Destroy event handler
|
180 |
-
dt.on( 'destroy.dtr', function () {
|
181 |
-
dt.off( '.dtr' );
|
182 |
-
$( dt.table().body() ).off( '.dtr' );
|
183 |
-
$(window).off( 'resize.dtr orientationchange.dtr' );
|
184 |
-
|
185 |
-
// Restore the columns that we've hidden
|
186 |
-
$.each( that.s.current, function ( i, val ) {
|
187 |
-
if ( val === false ) {
|
188 |
-
that._setColumnVis( i, true );
|
189 |
-
}
|
190 |
-
} );
|
191 |
-
} );
|
192 |
-
|
193 |
-
// Reorder the breakpoints array here in case they have been added out
|
194 |
-
// of order
|
195 |
-
this.c.breakpoints.sort( function (a, b) {
|
196 |
-
return a.width < b.width ? 1 :
|
197 |
-
a.width > b.width ? -1 : 0;
|
198 |
-
} );
|
199 |
-
|
200 |
-
this._classLogic();
|
201 |
-
this._resizeAuto();
|
202 |
-
|
203 |
-
// Details handler
|
204 |
-
var details = this.c.details;
|
205 |
-
|
206 |
-
if ( details.type !== false ) {
|
207 |
-
that._detailsInit();
|
208 |
-
|
209 |
-
// DataTables will trigger this event on every column it shows and
|
210 |
-
// hides individually
|
211 |
-
dt.on( 'column-visibility.dtr', function (e, ctx, col, vis) {
|
212 |
-
that._classLogic();
|
213 |
-
that._resizeAuto();
|
214 |
-
that._resize();
|
215 |
-
} );
|
216 |
-
|
217 |
-
// Redraw the details box on each draw which will happen if the data
|
218 |
-
// has changed. This is used until DataTables implements a native
|
219 |
-
// `updated` event for rows
|
220 |
-
dt.on( 'draw.dtr', function () {
|
221 |
-
that._redrawChildren();
|
222 |
-
} );
|
223 |
-
|
224 |
-
$(dt.table().node()).addClass( 'dtr-'+details.type );
|
225 |
-
}
|
226 |
-
|
227 |
-
dt.on( 'column-reorder.dtr', function (e, settings, details) {
|
228 |
-
that._classLogic();
|
229 |
-
that._resizeAuto();
|
230 |
-
that._resize();
|
231 |
-
} );
|
232 |
-
|
233 |
-
// Change in column sizes means we need to calc
|
234 |
-
dt.on( 'column-sizing.dtr', function () {
|
235 |
-
that._resizeAuto();
|
236 |
-
that._resize();
|
237 |
-
});
|
238 |
-
|
239 |
-
dt.on( 'init.dtr', function (e, settings, details) {
|
240 |
-
that._resizeAuto();
|
241 |
-
that._resize();
|
242 |
-
|
243 |
-
// If columns were hidden, then DataTables needs to adjust the
|
244 |
-
// column sizing
|
245 |
-
if ( $.inArray( false, that.s.current ) ) {
|
246 |
-
dt.columns.adjust();
|
247 |
-
}
|
248 |
-
} );
|
249 |
-
|
250 |
-
// First pass - draw the table for the current viewport size
|
251 |
-
this._resize();
|
252 |
-
},
|
253 |
-
|
254 |
-
|
255 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
256 |
-
* Private methods
|
257 |
-
*/
|
258 |
-
|
259 |
-
/**
|
260 |
-
* Calculate the visibility for the columns in a table for a given
|
261 |
-
* breakpoint. The result is pre-determined based on the class logic if
|
262 |
-
* class names are used to control all columns, but the width of the table
|
263 |
-
* is also used if there are columns which are to be automatically shown
|
264 |
-
* and hidden.
|
265 |
-
*
|
266 |
-
* @param {string} breakpoint Breakpoint name to use for the calculation
|
267 |
-
* @return {array} Array of boolean values initiating the visibility of each
|
268 |
-
* column.
|
269 |
-
* @private
|
270 |
-
*/
|
271 |
-
_columnsVisiblity: function ( breakpoint )
|
272 |
-
{
|
273 |
-
var dt = this.s.dt;
|
274 |
-
var columns = this.s.columns;
|
275 |
-
var i, ien;
|
276 |
-
|
277 |
-
// Create an array that defines the column ordering based first on the
|
278 |
-
// column's priority, and secondly the column index. This allows the
|
279 |
-
// columns to be removed from the right if the priority matches
|
280 |
-
var order = columns
|
281 |
-
.map( function ( col, idx ) {
|
282 |
-
return {
|
283 |
-
columnIdx: idx,
|
284 |
-
priority: col.priority
|
285 |
-
};
|
286 |
-
} )
|
287 |
-
.sort( function ( a, b ) {
|
288 |
-
if ( a.priority !== b.priority ) {
|
289 |
-
return a.priority - b.priority;
|
290 |
-
}
|
291 |
-
return a.columnIdx - b.columnIdx;
|
292 |
-
} );
|
293 |
-
|
294 |
-
// Class logic - determine which columns are in this breakpoint based
|
295 |
-
// on the classes. If no class control (i.e. `auto`) then `-` is used
|
296 |
-
// to indicate this to the rest of the function
|
297 |
-
var display = $.map( columns, function ( col ) {
|
298 |
-
return col.auto && col.minWidth === null ?
|
299 |
-
false :
|
300 |
-
col.auto === true ?
|
301 |
-
'-' :
|
302 |
-
$.inArray( breakpoint, col.includeIn ) !== -1;
|
303 |
-
} );
|
304 |
-
|
305 |
-
// Auto column control - first pass: how much width is taken by the
|
306 |
-
// ones that must be included from the non-auto columns
|
307 |
-
var requiredWidth = 0;
|
308 |
-
for ( i=0, ien=display.length ; i<ien ; i++ ) {
|
309 |
-
if ( display[i] === true ) {
|
310 |
-
requiredWidth += columns[i].minWidth;
|
311 |
-
}
|
312 |
-
}
|
313 |
-
|
314 |
-
// Second pass, use up any remaining width for other columns. For
|
315 |
-
// scrolling tables we need to subtract the width of the scrollbar. It
|
316 |
-
// may not be requires which makes this sub-optimal, but it would
|
317 |
-
// require another full redraw to make complete use of those extra few
|
318 |
-
// pixels
|
319 |
-
var scrolling = dt.settings()[0].oScroll;
|
320 |
-
var bar = scrolling.sY || scrolling.sX ? scrolling.iBarWidth : 0;
|
321 |
-
var widthAvailable = dt.table().container().offsetWidth - bar;
|
322 |
-
var usedWidth = widthAvailable - requiredWidth;
|
323 |
-
|
324 |
-
// Control column needs to always be included. This makes it sub-
|
325 |
-
// optimal in terms of using the available with, but to stop layout
|
326 |
-
// thrashing or overflow. Also we need to account for the control column
|
327 |
-
// width first so we know how much width is available for the other
|
328 |
-
// columns, since the control column might not be the first one shown
|
329 |
-
for ( i=0, ien=display.length ; i<ien ; i++ ) {
|
330 |
-
if ( columns[i].control ) {
|
331 |
-
usedWidth -= columns[i].minWidth;
|
332 |
-
}
|
333 |
-
}
|
334 |
-
|
335 |
-
// Allow columns to be shown (counting by priority and then right to
|
336 |
-
// left) until we run out of room
|
337 |
-
var empty = false;
|
338 |
-
for ( i=0, ien=order.length ; i<ien ; i++ ) {
|
339 |
-
var colIdx = order[i].columnIdx;
|
340 |
-
|
341 |
-
if ( display[colIdx] === '-' && ! columns[colIdx].control && columns[colIdx].minWidth ) {
|
342 |
-
// Once we've found a column that won't fit we don't let any
|
343 |
-
// others display either, or columns might disappear in the
|
344 |
-
// middle of the table
|
345 |
-
if ( empty || usedWidth - columns[colIdx].minWidth < 0 ) {
|
346 |
-
empty = true;
|
347 |
-
display[colIdx] = false;
|
348 |
-
}
|
349 |
-
else {
|
350 |
-
display[colIdx] = true;
|
351 |
-
}
|
352 |
-
|
353 |
-
usedWidth -= columns[colIdx].minWidth;
|
354 |
-
}
|
355 |
-
}
|
356 |
-
|
357 |
-
// Determine if the 'control' column should be shown (if there is one).
|
358 |
-
// This is the case when there is a hidden column (that is not the
|
359 |
-
// control column). The two loops look inefficient here, but they are
|
360 |
-
// trivial and will fly through. We need to know the outcome from the
|
361 |
-
// first , before the action in the second can be taken
|
362 |
-
var showControl = false;
|
363 |
-
|
364 |
-
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
365 |
-
if ( ! columns[i].control && ! columns[i].never && ! display[i] ) {
|
366 |
-
showControl = true;
|
367 |
-
break;
|
368 |
-
}
|
369 |
-
}
|
370 |
-
|
371 |
-
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
372 |
-
if ( columns[i].control ) {
|
373 |
-
display[i] = showControl;
|
374 |
-
}
|
375 |
-
}
|
376 |
-
|
377 |
-
// Finally we need to make sure that there is at least one column that
|
378 |
-
// is visible
|
379 |
-
if ( $.inArray( true, display ) === -1 ) {
|
380 |
-
display[0] = true;
|
381 |
-
}
|
382 |
-
|
383 |
-
return display;
|
384 |
-
},
|
385 |
-
|
386 |
-
|
387 |
-
/**
|
388 |
-
* Create the internal `columns` array with information about the columns
|
389 |
-
* for the table. This includes determining which breakpoints the column
|
390 |
-
* will appear in, based upon class names in the column, which makes up the
|
391 |
-
* vast majority of this method.
|
392 |
-
*
|
393 |
-
* @private
|
394 |
-
*/
|
395 |
-
_classLogic: function ()
|
396 |
-
{
|
397 |
-
var that = this;
|
398 |
-
var calc = {};
|
399 |
-
var breakpoints = this.c.breakpoints;
|
400 |
-
var dt = this.s.dt;
|
401 |
-
var columns = dt.columns().eq(0).map( function (i) {
|
402 |
-
var column = this.column(i);
|
403 |
-
var className = column.header().className;
|
404 |
-
var priority = dt.settings()[0].aoColumns[i].responsivePriority;
|
405 |
-
|
406 |
-
if ( priority === undefined ) {
|
407 |
-
var dataPriority = $(column.header()).data('priority');
|
408 |
-
|
409 |
-
priority = dataPriority !== undefined ?
|
410 |
-
dataPriority * 1 :
|
411 |
-
10000;
|
412 |
-
}
|
413 |
-
|
414 |
-
return {
|
415 |
-
className: className,
|
416 |
-
includeIn: [],
|
417 |
-
auto: false,
|
418 |
-
control: false,
|
419 |
-
never: className.match(/\bnever\b/) ? true : false,
|
420 |
-
priority: priority
|
421 |
-
};
|
422 |
-
} );
|
423 |
-
|
424 |
-
// Simply add a breakpoint to `includeIn` array, ensuring that there are
|
425 |
-
// no duplicates
|
426 |
-
var add = function ( colIdx, name ) {
|
427 |
-
var includeIn = columns[ colIdx ].includeIn;
|
428 |
-
|
429 |
-
if ( $.inArray( name, includeIn ) === -1 ) {
|
430 |
-
includeIn.push( name );
|
431 |
-
}
|
432 |
-
};
|
433 |
-
|
434 |
-
var column = function ( colIdx, name, operator, matched ) {
|
435 |
-
var size, i, ien;
|
436 |
-
|
437 |
-
if ( ! operator ) {
|
438 |
-
columns[ colIdx ].includeIn.push( name );
|
439 |
-
}
|
440 |
-
else if ( operator === 'max-' ) {
|
441 |
-
// Add this breakpoint and all smaller
|
442 |
-
size = that._find( name ).width;
|
443 |
-
|
444 |
-
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
445 |
-
if ( breakpoints[i].width <= size ) {
|
446 |
-
add( colIdx, breakpoints[i].name );
|
447 |
-
}
|
448 |
-
}
|
449 |
-
}
|
450 |
-
else if ( operator === 'min-' ) {
|
451 |
-
// Add this breakpoint and all larger
|
452 |
-
size = that._find( name ).width;
|
453 |
-
|
454 |
-
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
455 |
-
if ( breakpoints[i].width >= size ) {
|
456 |
-
add( colIdx, breakpoints[i].name );
|
457 |
-
}
|
458 |
-
}
|
459 |
-
}
|
460 |
-
else if ( operator === 'not-' ) {
|
461 |
-
// Add all but this breakpoint
|
462 |
-
for ( i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
463 |
-
if ( breakpoints[i].name.indexOf( matched ) === -1 ) {
|
464 |
-
add( colIdx, breakpoints[i].name );
|
465 |
-
}
|
466 |
-
}
|
467 |
-
}
|
468 |
-
};
|
469 |
-
|
470 |
-
// Loop over each column and determine if it has a responsive control
|
471 |
-
// class
|
472 |
-
columns.each( function ( col, i ) {
|
473 |
-
var classNames = col.className.split(' ');
|
474 |
-
var hasClass = false;
|
475 |
-
|
476 |
-
// Split the class name up so multiple rules can be applied if needed
|
477 |
-
for ( var k=0, ken=classNames.length ; k<ken ; k++ ) {
|
478 |
-
var className = $.trim( classNames[k] );
|
479 |
-
|
480 |
-
if ( className === 'all' ) {
|
481 |
-
// Include in all
|
482 |
-
hasClass = true;
|
483 |
-
col.includeIn = $.map( breakpoints, function (a) {
|
484 |
-
return a.name;
|
485 |
-
} );
|
486 |
-
return;
|
487 |
-
}
|
488 |
-
else if ( className === 'none' || col.never ) {
|
489 |
-
// Include in none (default) and no auto
|
490 |
-
hasClass = true;
|
491 |
-
return;
|
492 |
-
}
|
493 |
-
else if ( className === 'control' ) {
|
494 |
-
// Special column that is only visible, when one of the other
|
495 |
-
// columns is hidden. This is used for the details control
|
496 |
-
hasClass = true;
|
497 |
-
col.control = true;
|
498 |
-
return;
|
499 |
-
}
|
500 |
-
|
501 |
-
$.each( breakpoints, function ( j, breakpoint ) {
|
502 |
-
// Does this column have a class that matches this breakpoint?
|
503 |
-
var brokenPoint = breakpoint.name.split('-');
|
504 |
-
var re = new RegExp( '(min\\-|max\\-|not\\-)?('+brokenPoint[0]+')(\\-[_a-zA-Z0-9])?' );
|
505 |
-
var match = className.match( re );
|
506 |
-
|
507 |
-
if ( match ) {
|
508 |
-
hasClass = true;
|
509 |
-
|
510 |
-
if ( match[2] === brokenPoint[0] && match[3] === '-'+brokenPoint[1] ) {
|
511 |
-
// Class name matches breakpoint name fully
|
512 |
-
column( i, breakpoint.name, match[1], match[2]+match[3] );
|
513 |
-
}
|
514 |
-
else if ( match[2] === brokenPoint[0] && ! match[3] ) {
|
515 |
-
// Class name matched primary breakpoint name with no qualifier
|
516 |
-
column( i, breakpoint.name, match[1], match[2] );
|
517 |
-
}
|
518 |
-
}
|
519 |
-
} );
|
520 |
-
}
|
521 |
-
|
522 |
-
// If there was no control class, then automatic sizing is used
|
523 |
-
if ( ! hasClass ) {
|
524 |
-
col.auto = true;
|
525 |
-
}
|
526 |
-
} );
|
527 |
-
|
528 |
-
this.s.columns = columns;
|
529 |
-
},
|
530 |
-
|
531 |
-
|
532 |
-
/**
|
533 |
-
* Show the details for the child row
|
534 |
-
*
|
535 |
-
* @param {DataTables.Api} row API instance for the row
|
536 |
-
* @param {boolean} update Update flag
|
537 |
-
* @private
|
538 |
-
*/
|
539 |
-
_detailsDisplay: function ( row, update )
|
540 |
-
{
|
541 |
-
var that = this;
|
542 |
-
var dt = this.s.dt;
|
543 |
-
var details = this.c.details;
|
544 |
-
|
545 |
-
if ( details && details.type !== false ) {
|
546 |
-
var res = details.display( row, update, function () {
|
547 |
-
return details.renderer(
|
548 |
-
dt, row[0], that._detailsObj(row[0])
|
549 |
-
);
|
550 |
-
} );
|
551 |
-
|
552 |
-
if ( res === true || res === false ) {
|
553 |
-
$(dt.table().node()).triggerHandler( 'responsive-display.dt', [dt, row, res, update] );
|
554 |
-
}
|
555 |
-
}
|
556 |
-
},
|
557 |
-
|
558 |
-
|
559 |
-
/**
|
560 |
-
* Initialisation for the details handler
|
561 |
-
*
|
562 |
-
* @private
|
563 |
-
*/
|
564 |
-
_detailsInit: function ()
|
565 |
-
{
|
566 |
-
var that = this;
|
567 |
-
var dt = this.s.dt;
|
568 |
-
var details = this.c.details;
|
569 |
-
|
570 |
-
// The inline type always uses the first child as the target
|
571 |
-
if ( details.type === 'inline' ) {
|
572 |
-
details.target = 'td:first-child, th:first-child';
|
573 |
-
}
|
574 |
-
|
575 |
-
// Keyboard accessibility
|
576 |
-
dt.on( 'draw.dtr', function () {
|
577 |
-
that._tabIndexes();
|
578 |
-
} );
|
579 |
-
that._tabIndexes(); // Initial draw has already happened
|
580 |
-
|
581 |
-
$( dt.table().body() ).on( 'keyup.dtr', 'td, th', function (e) {
|
582 |
-
if ( e.keyCode === 13 && $(this).data('dtr-keyboard') ) {
|
583 |
-
$(this).click();
|
584 |
-
}
|
585 |
-
} );
|
586 |
-
|
587 |
-
// type.target can be a string jQuery selector or a column index
|
588 |
-
var target = details.target;
|
589 |
-
var selector = typeof target === 'string' ? target : 'td, th';
|
590 |
-
|
591 |
-
// Click handler to show / hide the details rows when they are available
|
592 |
-
$( dt.table().body() )
|
593 |
-
.on( 'click.dtr mousedown.dtr mouseup.dtr', selector, function (e) {
|
594 |
-
// If the table is not collapsed (i.e. there is no hidden columns)
|
595 |
-
// then take no action
|
596 |
-
if ( ! $(dt.table().node()).hasClass('collapsed' ) ) {
|
597 |
-
return;
|
598 |
-
}
|
599 |
-
|
600 |
-
// Check that the row is actually a DataTable's controlled node
|
601 |
-
if ( ! dt.row( $(this).closest('tr') ).length ) {
|
602 |
-
return;
|
603 |
-
}
|
604 |
-
|
605 |
-
// For column index, we determine if we should act or not in the
|
606 |
-
// handler - otherwise it is already okay
|
607 |
-
if ( typeof target === 'number' ) {
|
608 |
-
var targetIdx = target < 0 ?
|
609 |
-
dt.columns().eq(0).length + target :
|
610 |
-
target;
|
611 |
-
|
612 |
-
if ( dt.cell( this ).index().column !== targetIdx ) {
|
613 |
-
return;
|
614 |
-
}
|
615 |
-
}
|
616 |
-
|
617 |
-
// $().closest() includes itself in its check
|
618 |
-
var row = dt.row( $(this).closest('tr') );
|
619 |
-
|
620 |
-
// Check event type to do an action
|
621 |
-
if ( e.type === 'click' ) {
|
622 |
-
// The renderer is given as a function so the caller can execute it
|
623 |
-
// only when they need (i.e. if hiding there is no point is running
|
624 |
-
// the renderer)
|
625 |
-
that._detailsDisplay( row, false );
|
626 |
-
}
|
627 |
-
else if ( e.type === 'mousedown' ) {
|
628 |
-
// For mouse users, prevent the focus ring from showing
|
629 |
-
$(this).css('outline', 'none');
|
630 |
-
}
|
631 |
-
else if ( e.type === 'mouseup' ) {
|
632 |
-
// And then re-allow at the end of the click
|
633 |
-
$(this).blur().css('outline', '');
|
634 |
-
}
|
635 |
-
} );
|
636 |
-
},
|
637 |
-
|
638 |
-
|
639 |
-
/**
|
640 |
-
* Get the details to pass to a renderer for a row
|
641 |
-
* @param {int} rowIdx Row index
|
642 |
-
* @private
|
643 |
-
*/
|
644 |
-
_detailsObj: function ( rowIdx )
|
645 |
-
{
|
646 |
-
var that = this;
|
647 |
-
var dt = this.s.dt;
|
648 |
-
|
649 |
-
return $.map( this.s.columns, function( col, i ) {
|
650 |
-
// Never and control columns should not be passed to the renderer
|
651 |
-
if ( col.never || col.control ) {
|
652 |
-
return;
|
653 |
-
}
|
654 |
-
|
655 |
-
return {
|
656 |
-
title: dt.settings()[0].aoColumns[ i ].sTitle,
|
657 |
-
data: dt.cell( rowIdx, i ).render( that.c.orthogonal ),
|
658 |
-
hidden: dt.column( i ).visible() && !that.s.current[ i ],
|
659 |
-
columnIndex: i,
|
660 |
-
rowIndex: rowIdx
|
661 |
-
};
|
662 |
-
} );
|
663 |
-
},
|
664 |
-
|
665 |
-
|
666 |
-
/**
|
667 |
-
* Find a breakpoint object from a name
|
668 |
-
*
|
669 |
-
* @param {string} name Breakpoint name to find
|
670 |
-
* @return {object} Breakpoint description object
|
671 |
-
* @private
|
672 |
-
*/
|
673 |
-
_find: function ( name )
|
674 |
-
{
|
675 |
-
var breakpoints = this.c.breakpoints;
|
676 |
-
|
677 |
-
for ( var i=0, ien=breakpoints.length ; i<ien ; i++ ) {
|
678 |
-
if ( breakpoints[i].name === name ) {
|
679 |
-
return breakpoints[i];
|
680 |
-
}
|
681 |
-
}
|
682 |
-
},
|
683 |
-
|
684 |
-
|
685 |
-
/**
|
686 |
-
* Re-create the contents of the child rows as the display has changed in
|
687 |
-
* some way.
|
688 |
-
*
|
689 |
-
* @private
|
690 |
-
*/
|
691 |
-
_redrawChildren: function ()
|
692 |
-
{
|
693 |
-
var that = this;
|
694 |
-
var dt = this.s.dt;
|
695 |
-
|
696 |
-
dt.rows( {page: 'current'} ).iterator( 'row', function ( settings, idx ) {
|
697 |
-
var row = dt.row( idx );
|
698 |
-
|
699 |
-
that._detailsDisplay( dt.row( idx ), true );
|
700 |
-
} );
|
701 |
-
},
|
702 |
-
|
703 |
-
|
704 |
-
/**
|
705 |
-
* Alter the table display for a resized viewport. This involves first
|
706 |
-
* determining what breakpoint the window currently is in, getting the
|
707 |
-
* column visibilities to apply and then setting them.
|
708 |
-
*
|
709 |
-
* @private
|
710 |
-
*/
|
711 |
-
_resize: function ()
|
712 |
-
{
|
713 |
-
var that = this;
|
714 |
-
var dt = this.s.dt;
|
715 |
-
var width = $(window).width();
|
716 |
-
var breakpoints = this.c.breakpoints;
|
717 |
-
var breakpoint = breakpoints[0].name;
|
718 |
-
var columns = this.s.columns;
|
719 |
-
var i, ien;
|
720 |
-
var oldVis = this.s.current.slice();
|
721 |
-
|
722 |
-
// Determine what breakpoint we are currently at
|
723 |
-
for ( i=breakpoints.length-1 ; i>=0 ; i-- ) {
|
724 |
-
if ( width <= breakpoints[i].width ) {
|
725 |
-
breakpoint = breakpoints[i].name;
|
726 |
-
break;
|
727 |
-
}
|
728 |
-
}
|
729 |
-
|
730 |
-
// Show the columns for that break point
|
731 |
-
var columnsVis = this._columnsVisiblity( breakpoint );
|
732 |
-
this.s.current = columnsVis;
|
733 |
-
|
734 |
-
// Set the class before the column visibility is changed so event
|
735 |
-
// listeners know what the state is. Need to determine if there are
|
736 |
-
// any columns that are not visible but can be shown
|
737 |
-
var collapsedClass = false;
|
738 |
-
for ( i=0, ien=columns.length ; i<ien ; i++ ) {
|
739 |
-
if ( columnsVis[i] === false && ! columns[i].never && ! columns[i].control ) {
|
740 |
-
collapsedClass = true;
|
741 |
-
break;
|
742 |
-
}
|
743 |
-
}
|
744 |
-
|
745 |
-
$( dt.table().node() ).toggleClass( 'collapsed', collapsedClass );
|
746 |
-
|
747 |
-
var changed = false;
|
748 |
-
|
749 |
-
dt.columns().eq(0).each( function ( colIdx, i ) {
|
750 |
-
if ( columnsVis[i] !== oldVis[i] ) {
|
751 |
-
changed = true;
|
752 |
-
that._setColumnVis( colIdx, columnsVis[i] );
|
753 |
-
}
|
754 |
-
} );
|
755 |
-
|
756 |
-
if ( changed ) {
|
757 |
-
this._redrawChildren();
|
758 |
-
|
759 |
-
// Inform listeners of the change
|
760 |
-
$(dt.table().node()).trigger( 'responsive-resize.dt', [dt, this.s.current] );
|
761 |
-
}
|
762 |
-
},
|
763 |
-
|
764 |
-
|
765 |
-
/**
|
766 |
-
* Determine the width of each column in the table so the auto column hiding
|
767 |
-
* has that information to work with. This method is never going to be 100%
|
768 |
-
* perfect since column widths can change slightly per page, but without
|
769 |
-
* seriously compromising performance this is quite effective.
|
770 |
-
*
|
771 |
-
* @private
|
772 |
-
*/
|
773 |
-
_resizeAuto: function ()
|
774 |
-
{
|
775 |
-
var dt = this.s.dt;
|
776 |
-
var columns = this.s.columns;
|
777 |
-
|
778 |
-
// Are we allowed to do auto sizing?
|
779 |
-
if ( ! this.c.auto ) {
|
780 |
-
return;
|
781 |
-
}
|
782 |
-
|
783 |
-
// Are there any columns that actually need auto-sizing, or do they all
|
784 |
-
// have classes defined
|
785 |
-
if ( $.inArray( true, $.map( columns, function (c) { return c.auto; } ) ) === -1 ) {
|
786 |
-
return;
|
787 |
-
}
|
788 |
-
|
789 |
-
// Clone the table with the current data in it
|
790 |
-
var tableWidth = dt.table().node().offsetWidth;
|
791 |
-
var columnWidths = dt.columns;
|
792 |
-
var clonedTable = dt.table().node().cloneNode( false );
|
793 |
-
var clonedHeader = $( dt.table().header().cloneNode( false ) ).appendTo( clonedTable );
|
794 |
-
var clonedBody = $( dt.table().body() ).clone( false, false ).empty().appendTo( clonedTable ); // use jQuery because of IE8
|
795 |
-
|
796 |
-
// Header
|
797 |
-
var headerCells = dt.columns()
|
798 |
-
.header()
|
799 |
-
.filter( function (idx) {
|
800 |
-
return dt.column(idx).visible();
|
801 |
-
} )
|
802 |
-
.to$()
|
803 |
-
.clone( false )
|
804 |
-
.css( 'display', 'table-cell' );
|
805 |
-
|
806 |
-
// Body rows - we don't need to take account of DataTables' column
|
807 |
-
// visibility since we implement our own here (hence the `display` set)
|
808 |
-
$(clonedBody)
|
809 |
-
.append( $(dt.rows( { page: 'current' } ).nodes()).clone( false ) )
|
810 |
-
.find( 'th, td' ).css( 'display', '' );
|
811 |
-
|
812 |
-
// Footer
|
813 |
-
var footer = dt.table().footer();
|
814 |
-
if ( footer ) {
|
815 |
-
var clonedFooter = $( footer.cloneNode( false ) ).appendTo( clonedTable );
|
816 |
-
var footerCells = dt.columns()
|
817 |
-
.footer()
|
818 |
-
.filter( function (idx) {
|
819 |
-
return dt.column(idx).visible();
|
820 |
-
} )
|
821 |
-
.to$()
|
822 |
-
.clone( false )
|
823 |
-
.css( 'display', 'table-cell' );
|
824 |
-
|
825 |
-
$('<tr/>')
|
826 |
-
.append( footerCells )
|
827 |
-
.appendTo( clonedFooter );
|
828 |
-
}
|
829 |
-
|
830 |
-
$('<tr/>')
|
831 |
-
.append( headerCells )
|
832 |
-
.appendTo( clonedHeader );
|
833 |
-
|
834 |
-
// In the inline case extra padding is applied to the first column to
|
835 |
-
// give space for the show / hide icon. We need to use this in the
|
836 |
-
// calculation
|
837 |
-
if ( this.c.details.type === 'inline' ) {
|
838 |
-
$(clonedTable).addClass( 'dtr-inline collapsed' );
|
839 |
-
}
|
840 |
-
|
841 |
-
// It is unsafe to insert elements with the same name into the DOM
|
842 |
-
// multiple times. For example, cloning and inserting a checked radio
|
843 |
-
// clears the chcecked state of the original radio.
|
844 |
-
$( clonedTable ).find( '[name]' ).removeAttr( 'name' );
|
845 |
-
|
846 |
-
var inserted = $('<div/>')
|
847 |
-
.css( {
|
848 |
-
width: 1,
|
849 |
-
height: 1,
|
850 |
-
overflow: 'hidden'
|
851 |
-
} )
|
852 |
-
.append( clonedTable );
|
853 |
-
|
854 |
-
inserted.insertBefore( dt.table().node() );
|
855 |
-
|
856 |
-
// The cloned header now contains the smallest that each column can be
|
857 |
-
headerCells.each( function (i) {
|
858 |
-
var idx = dt.column.index( 'fromVisible', i );
|
859 |
-
columns[ idx ].minWidth = this.offsetWidth || 0;
|
860 |
-
} );
|
861 |
-
|
862 |
-
inserted.remove();
|
863 |
-
},
|
864 |
-
|
865 |
-
/**
|
866 |
-
* Set a column's visibility.
|
867 |
-
*
|
868 |
-
* We don't use DataTables' column visibility controls in order to ensure
|
869 |
-
* that column visibility can Responsive can no-exist. Since only IE8+ is
|
870 |
-
* supported (and all evergreen browsers of course) the control of the
|
871 |
-
* display attribute works well.
|
872 |
-
*
|
873 |
-
* @param {integer} col Column index
|
874 |
-
* @param {boolean} showHide Show or hide (true or false)
|
875 |
-
* @private
|
876 |
-
*/
|
877 |
-
_setColumnVis: function ( col, showHide )
|
878 |
-
{
|
879 |
-
var dt = this.s.dt;
|
880 |
-
var display = showHide ? '' : 'none'; // empty string will remove the attr
|
881 |
-
|
882 |
-
$( dt.column( col ).header() ).css( 'display', display );
|
883 |
-
$( dt.column( col ).footer() ).css( 'display', display );
|
884 |
-
dt.column( col ).nodes().to$().css( 'display', display );
|
885 |
-
},
|
886 |
-
|
887 |
-
|
888 |
-
/**
|
889 |
-
* Update the cell tab indexes for keyboard accessibility. This is called on
|
890 |
-
* every table draw - that is potentially inefficient, but also the least
|
891 |
-
* complex option given that column visibility can change on the fly. Its a
|
892 |
-
* shame user-focus was removed from CSS 3 UI, as it would have solved this
|
893 |
-
* issue with a single CSS statement.
|
894 |
-
*
|
895 |
-
* @private
|
896 |
-
*/
|
897 |
-
_tabIndexes: function ()
|
898 |
-
{
|
899 |
-
var dt = this.s.dt;
|
900 |
-
var cells = dt.cells( { page: 'current' } ).nodes().to$();
|
901 |
-
var ctx = dt.settings()[0];
|
902 |
-
var target = this.c.details.target;
|
903 |
-
|
904 |
-
cells.filter( '[data-dtr-keyboard]' ).removeData( '[data-dtr-keyboard]' );
|
905 |
-
|
906 |
-
var selector = typeof target === 'number' ?
|
907 |
-
':eq('+target+')' :
|
908 |
-
target;
|
909 |
-
|
910 |
-
$( selector, dt.rows( { page: 'current' } ).nodes() )
|
911 |
-
.attr( 'tabIndex', ctx.iTabIndex )
|
912 |
-
.data( 'dtr-keyboard', 1 );
|
913 |
-
}
|
914 |
-
} );
|
915 |
-
|
916 |
-
|
917 |
-
/**
|
918 |
-
* List of default breakpoints. Each item in the array is an object with two
|
919 |
-
* properties:
|
920 |
-
*
|
921 |
-
* * `name` - the breakpoint name.
|
922 |
-
* * `width` - the breakpoint width
|
923 |
-
*
|
924 |
-
* @name Responsive.breakpoints
|
925 |
-
* @static
|
926 |
-
*/
|
927 |
-
Responsive.breakpoints = [
|
928 |
-
{ name: 'desktop', width: Infinity },
|
929 |
-
{ name: 'tablet-l', width: 1024 },
|
930 |
-
{ name: 'tablet-p', width: 768 },
|
931 |
-
{ name: 'mobile-l', width: 480 },
|
932 |
-
{ name: 'mobile-p', width: 320 }
|
933 |
-
];
|
934 |
-
|
935 |
-
|
936 |
-
/**
|
937 |
-
* Display methods - functions which define how the hidden data should be shown
|
938 |
-
* in the table.
|
939 |
-
*
|
940 |
-
* @namespace
|
941 |
-
* @name Responsive.defaults
|
942 |
-
* @static
|
943 |
-
*/
|
944 |
-
Responsive.display = {
|
945 |
-
childRow: function ( row, update, render ) {
|
946 |
-
if ( update ) {
|
947 |
-
if ( $(row.node()).hasClass('parent') ) {
|
948 |
-
row.child( render(), 'child' ).show();
|
949 |
-
|
950 |
-
return true;
|
951 |
-
}
|
952 |
-
}
|
953 |
-
else {
|
954 |
-
if ( ! row.child.isShown() ) {
|
955 |
-
row.child( render(), 'child' ).show();
|
956 |
-
$( row.node() ).addClass( 'parent' );
|
957 |
-
|
958 |
-
return true;
|
959 |
-
}
|
960 |
-
else {
|
961 |
-
row.child( false );
|
962 |
-
$( row.node() ).removeClass( 'parent' );
|
963 |
-
|
964 |
-
return false;
|
965 |
-
}
|
966 |
-
}
|
967 |
-
},
|
968 |
-
|
969 |
-
childRowImmediate: function ( row, update, render ) {
|
970 |
-
if ( (! update && row.child.isShown()) || ! row.responsive.hasHidden() ) {
|
971 |
-
// User interaction and the row is show, or nothing to show
|
972 |
-
row.child( false );
|
973 |
-
$( row.node() ).removeClass( 'parent' );
|
974 |
-
|
975 |
-
return false;
|
976 |
-
}
|
977 |
-
else {
|
978 |
-
// Display
|
979 |
-
row.child( render(), 'child' ).show();
|
980 |
-
$( row.node() ).addClass( 'parent' );
|
981 |
-
|
982 |
-
return true;
|
983 |
-
}
|
984 |
-
},
|
985 |
-
|
986 |
-
// This is a wrapper so the modal options for Bootstrap and jQuery UI can
|
987 |
-
// have options passed into them. This specific one doesn't need to be a
|
988 |
-
// function but it is for consistency in the `modal` name
|
989 |
-
modal: function ( options ) {
|
990 |
-
return function ( row, update, render ) {
|
991 |
-
if ( ! update ) {
|
992 |
-
// Show a modal
|
993 |
-
var close = function () {
|
994 |
-
modal.remove(); // will tidy events for us
|
995 |
-
$(document).off( 'keypress.dtr' );
|
996 |
-
};
|
997 |
-
|
998 |
-
var modal = $('<div class="dtr-modal"/>')
|
999 |
-
.append( $('<div class="dtr-modal-display"/>')
|
1000 |
-
.append( $('<div class="dtr-modal-content"/>')
|
1001 |
-
.append( render() )
|
1002 |
-
)
|
1003 |
-
.append( $('<div class="dtr-modal-close">×</div>' )
|
1004 |
-
.click( function () {
|
1005 |
-
close();
|
1006 |
-
} )
|
1007 |
-
)
|
1008 |
-
)
|
1009 |
-
.append( $('<div class="dtr-modal-background"/>')
|
1010 |
-
.click( function () {
|
1011 |
-
close();
|
1012 |
-
} )
|
1013 |
-
)
|
1014 |
-
.appendTo( 'body' );
|
1015 |
-
|
1016 |
-
$(document).on( 'keyup.dtr', function (e) {
|
1017 |
-
if ( e.keyCode === 27 ) {
|
1018 |
-
e.stopPropagation();
|
1019 |
-
|
1020 |
-
close();
|
1021 |
-
}
|
1022 |
-
} );
|
1023 |
-
}
|
1024 |
-
else {
|
1025 |
-
$('div.dtr-modal-content')
|
1026 |
-
.empty()
|
1027 |
-
.append( render() );
|
1028 |
-
}
|
1029 |
-
|
1030 |
-
if ( options && options.header ) {
|
1031 |
-
$('div.dtr-modal-content').prepend(
|
1032 |
-
'<h2>'+options.header( row )+'</h2>'
|
1033 |
-
);
|
1034 |
-
}
|
1035 |
-
};
|
1036 |
-
}
|
1037 |
-
};
|
1038 |
-
|
1039 |
-
|
1040 |
-
/**
|
1041 |
-
* Display methods - functions which define how the hidden data should be shown
|
1042 |
-
* in the table.
|
1043 |
-
*
|
1044 |
-
* @namespace
|
1045 |
-
* @name Responsive.defaults
|
1046 |
-
* @static
|
1047 |
-
*/
|
1048 |
-
Responsive.renderer = {
|
1049 |
-
listHidden: function () {
|
1050 |
-
return function ( api, rowIdx, columns ) {
|
1051 |
-
var data = $.map( columns, function ( col ) {
|
1052 |
-
return col.hidden ?
|
1053 |
-
'<li data-dtr-index="'+col.columnIndex+'" data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">'+
|
1054 |
-
'<span class="dtr-title">'+
|
1055 |
-
col.title+
|
1056 |
-
'</span> '+
|
1057 |
-
'<span class="dtr-data">'+
|
1058 |
-
col.data+
|
1059 |
-
'</span>'+
|
1060 |
-
'</li>' :
|
1061 |
-
'';
|
1062 |
-
} ).join('');
|
1063 |
-
|
1064 |
-
return data ?
|
1065 |
-
$('<ul data-dtr-index="'+rowIdx+'"/>').append( data ) :
|
1066 |
-
false;
|
1067 |
-
}
|
1068 |
-
},
|
1069 |
-
|
1070 |
-
tableAll: function ( options ) {
|
1071 |
-
options = $.extend( {
|
1072 |
-
tableClass: ''
|
1073 |
-
}, options );
|
1074 |
-
|
1075 |
-
return function ( api, rowIdx, columns ) {
|
1076 |
-
var data = $.map( columns, function ( col ) {
|
1077 |
-
return '<tr data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">'+
|
1078 |
-
'<td>'+col.title+':'+'</td> '+
|
1079 |
-
'<td>'+col.data+'</td>'+
|
1080 |
-
'</tr>';
|
1081 |
-
} ).join('');
|
1082 |
-
|
1083 |
-
return $('<table class="'+options.tableClass+'" width="100%"/>').append( data );
|
1084 |
-
}
|
1085 |
-
}
|
1086 |
-
};
|
1087 |
-
|
1088 |
-
/**
|
1089 |
-
* Responsive default settings for initialisation
|
1090 |
-
*
|
1091 |
-
* @namespace
|
1092 |
-
* @name Responsive.defaults
|
1093 |
-
* @static
|
1094 |
-
*/
|
1095 |
-
Responsive.defaults = {
|
1096 |
-
/**
|
1097 |
-
* List of breakpoints for the instance. Note that this means that each
|
1098 |
-
* instance can have its own breakpoints. Additionally, the breakpoints
|
1099 |
-
* cannot be changed once an instance has been creased.
|
1100 |
-
*
|
1101 |
-
* @type {Array}
|
1102 |
-
* @default Takes the value of `Responsive.breakpoints`
|
1103 |
-
*/
|
1104 |
-
breakpoints: Responsive.breakpoints,
|
1105 |
-
|
1106 |
-
/**
|
1107 |
-
* Enable / disable auto hiding calculations. It can help to increase
|
1108 |
-
* performance slightly if you disable this option, but all columns would
|
1109 |
-
* need to have breakpoint classes assigned to them
|
1110 |
-
*
|
1111 |
-
* @type {Boolean}
|
1112 |
-
* @default `true`
|
1113 |
-
*/
|
1114 |
-
auto: true,
|
1115 |
-
|
1116 |
-
/**
|
1117 |
-
* Details control. If given as a string value, the `type` property of the
|
1118 |
-
* default object is set to that value, and the defaults used for the rest
|
1119 |
-
* of the object - this is for ease of implementation.
|
1120 |
-
*
|
1121 |
-
* The object consists of the following properties:
|
1122 |
-
*
|
1123 |
-
* * `display` - A function that is used to show and hide the hidden details
|
1124 |
-
* * `renderer` - function that is called for display of the child row data.
|
1125 |
-
* The default function will show the data from the hidden columns
|
1126 |
-
* * `target` - Used as the selector for what objects to attach the child
|
1127 |
-
* open / close to
|
1128 |
-
* * `type` - `false` to disable the details display, `inline` or `column`
|
1129 |
-
* for the two control types
|
1130 |
-
*
|
1131 |
-
* @type {Object|string}
|
1132 |
-
*/
|
1133 |
-
details: {
|
1134 |
-
display: Responsive.display.childRow,
|
1135 |
-
|
1136 |
-
renderer: Responsive.renderer.listHidden(),
|
1137 |
-
|
1138 |
-
target: 0,
|
1139 |
-
|
1140 |
-
type: 'inline'
|
1141 |
-
},
|
1142 |
-
|
1143 |
-
/**
|
1144 |
-
* Orthogonal data request option. This is used to define the data type
|
1145 |
-
* requested when Responsive gets the data to show in the child row.
|
1146 |
-
*
|
1147 |
-
* @type {String}
|
1148 |
-
*/
|
1149 |
-
orthogonal: 'display'
|
1150 |
-
};
|
1151 |
-
|
1152 |
-
|
1153 |
-
/*
|
1154 |
-
* API
|
1155 |
-
*/
|
1156 |
-
var Api = $.fn.dataTable.Api;
|
1157 |
-
|
1158 |
-
// Doesn't do anything - work around for a bug in DT... Not documented
|
1159 |
-
Api.register( 'responsive()', function () {
|
1160 |
-
return this;
|
1161 |
-
} );
|
1162 |
-
|
1163 |
-
Api.register( 'responsive.index()', function ( li ) {
|
1164 |
-
li = $(li);
|
1165 |
-
|
1166 |
-
return {
|
1167 |
-
column: li.data('dtr-index'),
|
1168 |
-
row: li.parent().data('dtr-index')
|
1169 |
-
};
|
1170 |
-
} );
|
1171 |
-
|
1172 |
-
Api.register( 'responsive.rebuild()', function () {
|
1173 |
-
return this.iterator( 'table', function ( ctx ) {
|
1174 |
-
if ( ctx._responsive ) {
|
1175 |
-
ctx._responsive._classLogic();
|
1176 |
-
}
|
1177 |
-
} );
|
1178 |
-
} );
|
1179 |
-
|
1180 |
-
Api.register( 'responsive.recalc()', function () {
|
1181 |
-
return this.iterator( 'table', function ( ctx ) {
|
1182 |
-
if ( ctx._responsive ) {
|
1183 |
-
ctx._responsive._resizeAuto();
|
1184 |
-
ctx._responsive._resize();
|
1185 |
-
}
|
1186 |
-
} );
|
1187 |
-
} );
|
1188 |
-
|
1189 |
-
Api.register( 'responsive.hasHidden()', function () {
|
1190 |
-
var ctx = this.context[0];
|
1191 |
-
|
1192 |
-
return ctx._responsive ?
|
1193 |
-
$.inArray( false, ctx._responsive.s.current ) !== -1 :
|
1194 |
-
false;
|
1195 |
-
} );
|
1196 |
-
|
1197 |
-
|
1198 |
-
/**
|
1199 |
-
* Version information
|
1200 |
-
*
|
1201 |
-
* @name Responsive.version
|
1202 |
-
* @static
|
1203 |
-
*/
|
1204 |
-
Responsive.version = '2.1.0';
|
1205 |
-
|
1206 |
-
|
1207 |
-
$.fn.dataTable.Responsive = Responsive;
|
1208 |
-
$.fn.DataTable.Responsive = Responsive;
|
1209 |
-
|
1210 |
-
// Attach a listener to the document which listens for DataTables initialisation
|
1211 |
-
// events so we can automatically initialise
|
1212 |
-
$(document).on( 'preInit.dt.dtr', function (e, settings, json) {
|
1213 |
-
if ( e.namespace !== 'dt' ) {
|
1214 |
-
return;
|
1215 |
-
}
|
1216 |
-
|
1217 |
-
if ( $(settings.nTable).hasClass( 'responsive' ) ||
|
1218 |
-
$(settings.nTable).hasClass( 'dt-responsive' ) ||
|
1219 |
-
settings.oInit.responsive ||
|
1220 |
-
DataTable.defaults.responsive
|
1221 |
-
) {
|
1222 |
-
var init = settings.oInit.responsive;
|
1223 |
-
|
1224 |
-
if ( init !== false ) {
|
1225 |
-
new Responsive( settings, $.isPlainObject( init ) ? init : {} );
|
1226 |
-
}
|
1227 |
-
}
|
1228 |
-
} );
|
1229 |
-
|
1230 |
-
|
1231 |
-
return Responsive;
|
1232 |
-
}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Responsive/js/dataTables.responsive.min.js
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
/*!
|
2 |
-
Responsive 2.1.0
|
3 |
-
2014-2016 SpryMedia Ltd - datatables.net/license
|
4 |
-
*/
|
5 |
-
(function(c){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(l){return c(l,window,document)}):"object"===typeof exports?module.exports=function(l,k){l||(l=window);if(!k||!k.fn.dataTable)k=require("datatables.net")(l,k).$;return c(k,l,l.document)}:c(jQuery,window,document)})(function(c,l,k,p){var m=c.fn.dataTable,j=function(a,b){if(!m.versionCheck||!m.versionCheck("1.10.3"))throw"DataTables Responsive requires DataTables 1.10.3 or newer";this.s={dt:new m.Api(a),columns:[],
|
6 |
-
current:[]};this.s.dt.settings()[0].responsive||(b&&"string"===typeof b.details?b.details={type:b.details}:b&&!1===b.details?b.details={type:!1}:b&&!0===b.details&&(b.details={type:"inline"}),this.c=c.extend(!0,{},j.defaults,m.defaults.responsive,b),a.responsive=this,this._constructor())};c.extend(j.prototype,{_constructor:function(){var a=this,b=this.s.dt,d=b.settings()[0],e=c(l).width();b.settings()[0]._responsive=this;c(l).on("resize.dtr orientationchange.dtr",m.util.throttle(function(){var b=
|
7 |
-
c(l).width();b!==e&&(a._resize(),e=b)}));d.oApi._fnCallbackReg(d,"aoRowCreatedCallback",function(e){-1!==c.inArray(!1,a.s.current)&&c("td, th",e).each(function(e){e=b.column.index("toData",e);!1===a.s.current[e]&&c(this).css("display","none")})});b.on("destroy.dtr",function(){b.off(".dtr");c(b.table().body()).off(".dtr");c(l).off("resize.dtr orientationchange.dtr");c.each(a.s.current,function(b,e){!1===e&&a._setColumnVis(b,!0)})});this.c.breakpoints.sort(function(a,b){return a.width<b.width?1:a.width>
|
8 |
-
b.width?-1:0});this._classLogic();this._resizeAuto();d=this.c.details;!1!==d.type&&(a._detailsInit(),b.on("column-visibility.dtr",function(){a._classLogic();a._resizeAuto();a._resize()}),b.on("draw.dtr",function(){a._redrawChildren()}),c(b.table().node()).addClass("dtr-"+d.type));b.on("column-reorder.dtr",function(){a._classLogic();a._resizeAuto();a._resize()});b.on("column-sizing.dtr",function(){a._resizeAuto();a._resize()});b.on("init.dtr",function(){a._resizeAuto();a._resize();c.inArray(false,
|
9 |
-
a.s.current)&&b.columns.adjust()});this._resize()},_columnsVisiblity:function(a){var b=this.s.dt,d=this.s.columns,e,f,g=d.map(function(a,b){return{columnIdx:b,priority:a.priority}}).sort(function(a,b){return a.priority!==b.priority?a.priority-b.priority:a.columnIdx-b.columnIdx}),h=c.map(d,function(b){return b.auto&&null===b.minWidth?!1:!0===b.auto?"-":-1!==c.inArray(a,b.includeIn)}),n=0;e=0;for(f=h.length;e<f;e++)!0===h[e]&&(n+=d[e].minWidth);e=b.settings()[0].oScroll;e=e.sY||e.sX?e.iBarWidth:0;b=
|
10 |
-
b.table().container().offsetWidth-e-n;e=0;for(f=h.length;e<f;e++)d[e].control&&(b-=d[e].minWidth);n=!1;e=0;for(f=g.length;e<f;e++){var i=g[e].columnIdx;"-"===h[i]&&(!d[i].control&&d[i].minWidth)&&(n||0>b-d[i].minWidth?(n=!0,h[i]=!1):h[i]=!0,b-=d[i].minWidth)}g=!1;e=0;for(f=d.length;e<f;e++)if(!d[e].control&&!d[e].never&&!h[e]){g=!0;break}e=0;for(f=d.length;e<f;e++)d[e].control&&(h[e]=g);-1===c.inArray(!0,h)&&(h[0]=!0);return h},_classLogic:function(){var a=this,b=this.c.breakpoints,d=this.s.dt,e=
|
11 |
-
d.columns().eq(0).map(function(a){var b=this.column(a),e=b.header().className,a=d.settings()[0].aoColumns[a].responsivePriority;a===p&&(b=c(b.header()).data("priority"),a=b!==p?1*b:1E4);return{className:e,includeIn:[],auto:!1,control:!1,never:e.match(/\bnever\b/)?!0:!1,priority:a}}),f=function(a,b){var d=e[a].includeIn;-1===c.inArray(b,d)&&d.push(b)},g=function(c,d,i,g){if(i)if("max-"===i){g=a._find(d).width;d=0;for(i=b.length;d<i;d++)b[d].width<=g&&f(c,b[d].name)}else if("min-"===i){g=a._find(d).width;
|
12 |
-
d=0;for(i=b.length;d<i;d++)b[d].width>=g&&f(c,b[d].name)}else{if("not-"===i){d=0;for(i=b.length;d<i;d++)-1===b[d].name.indexOf(g)&&f(c,b[d].name)}}else e[c].includeIn.push(d)};e.each(function(a,e){for(var d=a.className.split(" "),f=!1,j=0,l=d.length;j<l;j++){var k=c.trim(d[j]);if("all"===k){f=!0;a.includeIn=c.map(b,function(a){return a.name});return}if("none"===k||a.never){f=!0;return}if("control"===k){f=!0;a.control=!0;return}c.each(b,function(a,b){var d=b.name.split("-"),c=k.match(RegExp("(min\\-|max\\-|not\\-)?("+
|
13 |
-
d[0]+")(\\-[_a-zA-Z0-9])?"));c&&(f=!0,c[2]===d[0]&&c[3]==="-"+d[1]?g(e,b.name,c[1],c[2]+c[3]):c[2]===d[0]&&!c[3]&&g(e,b.name,c[1],c[2]))})}f||(a.auto=!0)});this.s.columns=e},_detailsDisplay:function(a,b){var d=this,e=this.s.dt,f=this.c.details;if(f&&!1!==f.type){var g=f.display(a,b,function(){return f.renderer(e,a[0],d._detailsObj(a[0]))});(!0===g||!1===g)&&c(e.table().node()).triggerHandler("responsive-display.dt",[e,a,g,b])}},_detailsInit:function(){var a=this,b=this.s.dt,d=this.c.details;"inline"===
|
14 |
-
d.type&&(d.target="td:first-child, th:first-child");b.on("draw.dtr",function(){a._tabIndexes()});a._tabIndexes();c(b.table().body()).on("keyup.dtr","td, th",function(a){a.keyCode===13&&c(this).data("dtr-keyboard")&&c(this).click()});var e=d.target;c(b.table().body()).on("click.dtr mousedown.dtr mouseup.dtr","string"===typeof e?e:"td, th",function(d){if(c(b.table().node()).hasClass("collapsed")&&b.row(c(this).closest("tr")).length){if(typeof e==="number"){var g=e<0?b.columns().eq(0).length+e:e;if(b.cell(this).index().column!==
|
15 |
-
g)return}g=b.row(c(this).closest("tr"));d.type==="click"?a._detailsDisplay(g,false):d.type==="mousedown"?c(this).css("outline","none"):d.type==="mouseup"&&c(this).blur().css("outline","")}})},_detailsObj:function(a){var b=this,d=this.s.dt;return c.map(this.s.columns,function(e,c){if(!e.never&&!e.control)return{title:d.settings()[0].aoColumns[c].sTitle,data:d.cell(a,c).render(b.c.orthogonal),hidden:d.column(c).visible()&&!b.s.current[c],columnIndex:c,rowIndex:a}})},_find:function(a){for(var b=this.c.breakpoints,
|
16 |
-
d=0,c=b.length;d<c;d++)if(b[d].name===a)return b[d]},_redrawChildren:function(){var a=this,b=this.s.dt;b.rows({page:"current"}).iterator("row",function(c,e){b.row(e);a._detailsDisplay(b.row(e),!0)})},_resize:function(){var a=this,b=this.s.dt,d=c(l).width(),e=this.c.breakpoints,f=e[0].name,g=this.s.columns,h,j=this.s.current.slice();for(h=e.length-1;0<=h;h--)if(d<=e[h].width){f=e[h].name;break}var i=this._columnsVisiblity(f);this.s.current=i;e=!1;h=0;for(d=g.length;h<d;h++)if(!1===i[h]&&!g[h].never&&
|
17 |
-
!g[h].control){e=!0;break}c(b.table().node()).toggleClass("collapsed",e);var k=!1;b.columns().eq(0).each(function(b,c){i[c]!==j[c]&&(k=!0,a._setColumnVis(b,i[c]))});k&&(this._redrawChildren(),c(b.table().node()).trigger("responsive-resize.dt",[b,this.s.current]))},_resizeAuto:function(){var a=this.s.dt,b=this.s.columns;if(this.c.auto&&-1!==c.inArray(!0,c.map(b,function(a){return a.auto}))){a.table().node();var d=a.table().node().cloneNode(!1),e=c(a.table().header().cloneNode(!1)).appendTo(d),f=c(a.table().body()).clone(!1,
|
18 |
-
!1).empty().appendTo(d),g=a.columns().header().filter(function(b){return a.column(b).visible()}).to$().clone(!1).css("display","table-cell");c(f).append(c(a.rows({page:"current"}).nodes()).clone(!1)).find("th, td").css("display","");if(f=a.table().footer()){var f=c(f.cloneNode(!1)).appendTo(d),h=a.columns().footer().filter(function(b){return a.column(b).visible()}).to$().clone(!1).css("display","table-cell");c("<tr/>").append(h).appendTo(f)}c("<tr/>").append(g).appendTo(e);"inline"===this.c.details.type&&
|
19 |
-
c(d).addClass("dtr-inline collapsed");c(d).find("[name]").removeAttr("name");d=c("<div/>").css({width:1,height:1,overflow:"hidden"}).append(d);d.insertBefore(a.table().node());g.each(function(c){c=a.column.index("fromVisible",c);b[c].minWidth=this.offsetWidth||0});d.remove()}},_setColumnVis:function(a,b){var d=this.s.dt,e=b?"":"none";c(d.column(a).header()).css("display",e);c(d.column(a).footer()).css("display",e);d.column(a).nodes().to$().css("display",e)},_tabIndexes:function(){var a=this.s.dt,
|
20 |
-
b=a.cells({page:"current"}).nodes().to$(),d=a.settings()[0],e=this.c.details.target;b.filter("[data-dtr-keyboard]").removeData("[data-dtr-keyboard]");c("number"===typeof e?":eq("+e+")":e,a.rows({page:"current"}).nodes()).attr("tabIndex",d.iTabIndex).data("dtr-keyboard",1)}});j.breakpoints=[{name:"desktop",width:Infinity},{name:"tablet-l",width:1024},{name:"tablet-p",width:768},{name:"mobile-l",width:480},{name:"mobile-p",width:320}];j.display={childRow:function(a,b,d){if(b){if(c(a.node()).hasClass("parent"))return a.child(d(),
|
21 |
-
"child").show(),!0}else{if(a.child.isShown())return a.child(!1),c(a.node()).removeClass("parent"),!1;a.child(d(),"child").show();c(a.node()).addClass("parent");return!0}},childRowImmediate:function(a,b,d){if(!b&&a.child.isShown()||!a.responsive.hasHidden())return a.child(!1),c(a.node()).removeClass("parent"),!1;a.child(d(),"child").show();c(a.node()).addClass("parent");return!0},modal:function(a){return function(b,d,e){if(d)c("div.dtr-modal-content").empty().append(e());else{var f=function(){g.remove();
|
22 |
-
c(k).off("keypress.dtr")},g=c('<div class="dtr-modal"/>').append(c('<div class="dtr-modal-display"/>').append(c('<div class="dtr-modal-content"/>').append(e())).append(c('<div class="dtr-modal-close">×</div>').click(function(){f()}))).append(c('<div class="dtr-modal-background"/>').click(function(){f()})).appendTo("body");c(k).on("keyup.dtr",function(a){27===a.keyCode&&(a.stopPropagation(),f())})}a&&a.header&&c("div.dtr-modal-content").prepend("<h2>"+a.header(b)+"</h2>")}}};j.renderer={listHidden:function(){return function(a,
|
23 |
-
b,d){return(a=c.map(d,function(a){return a.hidden?'<li data-dtr-index="'+a.columnIndex+'" data-dt-row="'+a.rowIndex+'" data-dt-column="'+a.columnIndex+'"><span class="dtr-title">'+a.title+'</span> <span class="dtr-data">'+a.data+"</span></li>":""}).join(""))?c('<ul data-dtr-index="'+b+'"/>').append(a):!1}},tableAll:function(a){a=c.extend({tableClass:""},a);return function(b,d,e){b=c.map(e,function(a){return'<tr data-dt-row="'+a.rowIndex+'" data-dt-column="'+a.columnIndex+'"><td>'+a.title+":</td> <td>"+
|
24 |
-
a.data+"</td></tr>"}).join("");return c('<table class="'+a.tableClass+'" width="100%"/>').append(b)}}};j.defaults={breakpoints:j.breakpoints,auto:!0,details:{display:j.display.childRow,renderer:j.renderer.listHidden(),target:0,type:"inline"},orthogonal:"display"};var o=c.fn.dataTable.Api;o.register("responsive()",function(){return this});o.register("responsive.index()",function(a){a=c(a);return{column:a.data("dtr-index"),row:a.parent().data("dtr-index")}});o.register("responsive.rebuild()",function(){return this.iterator("table",
|
25 |
-
function(a){a._responsive&&a._responsive._classLogic()})});o.register("responsive.recalc()",function(){return this.iterator("table",function(a){a._responsive&&(a._responsive._resizeAuto(),a._responsive._resize())})});o.register("responsive.hasHidden()",function(){var a=this.context[0];return a._responsive?-1!==c.inArray(!1,a._responsive.s.current):!1});j.version="2.1.0";c.fn.dataTable.Responsive=j;c.fn.DataTable.Responsive=j;c(k).on("preInit.dt.dtr",function(a,b){if("dt"===a.namespace&&(c(b.nTable).hasClass("responsive")||
|
26 |
-
c(b.nTable).hasClass("dt-responsive")||b.oInit.responsive||m.defaults.responsive)){var d=b.oInit.responsive;!1!==d&&new j(b,c.isPlainObject(d)?d:{})}});return j});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Scroller/css/scroller.dataTables.css
DELETED
@@ -1,20 +0,0 @@
|
|
1 |
-
div.DTS {
|
2 |
-
display: block !important;
|
3 |
-
}
|
4 |
-
div.DTS tbody th,
|
5 |
-
div.DTS tbody td {
|
6 |
-
white-space: nowrap;
|
7 |
-
}
|
8 |
-
div.DTS div.DTS_Loading {
|
9 |
-
z-index: 1;
|
10 |
-
}
|
11 |
-
div.DTS div.dataTables_scrollBody {
|
12 |
-
background: repeating-linear-gradient(45deg, #edeeff, #edeeff 10px, white 10px, white 20px);
|
13 |
-
}
|
14 |
-
div.DTS div.dataTables_scrollBody table {
|
15 |
-
z-index: 2;
|
16 |
-
}
|
17 |
-
div.DTS div.dataTables_paginate,
|
18 |
-
div.DTS div.dataTables_length {
|
19 |
-
display: none;
|
20 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Scroller/css/scroller.dataTables.min.css
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
div.DTS{display:block !important}div.DTS tbody th,div.DTS tbody td{white-space:nowrap}div.DTS div.DTS_Loading{z-index:1}div.DTS div.dataTables_scrollBody{background:repeating-linear-gradient(45deg, #edeeff, #edeeff 10px, #fff 10px, #fff 20px)}div.DTS div.dataTables_scrollBody table{z-index:2}div.DTS div.dataTables_paginate,div.DTS div.dataTables_length{display:none}
|
|
common/vendor/datatables/extensions/Scroller/js/dataTables.scroller.js
DELETED
@@ -1,1349 +0,0 @@
|
|
1 |
-
/*! Scroller 1.4.2
|
2 |
-
* ©2011-2016 SpryMedia Ltd - datatables.net/license
|
3 |
-
*/
|
4 |
-
|
5 |
-
/**
|
6 |
-
* @summary Scroller
|
7 |
-
* @description Virtual rendering for DataTables
|
8 |
-
* @version 1.4.2
|
9 |
-
* @file dataTables.scroller.js
|
10 |
-
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
11 |
-
* @contact www.sprymedia.co.uk/contact
|
12 |
-
* @copyright Copyright 2011-2016 SpryMedia Ltd.
|
13 |
-
*
|
14 |
-
* This source file is free software, available under the following license:
|
15 |
-
* MIT license - http://datatables.net/license/mit
|
16 |
-
*
|
17 |
-
* This source file is distributed in the hope that it will be useful, but
|
18 |
-
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
19 |
-
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
20 |
-
*
|
21 |
-
* For details please refer to: http://www.datatables.net
|
22 |
-
*/
|
23 |
-
|
24 |
-
(function( factory ){
|
25 |
-
if ( typeof define === 'function' && define.amd ) {
|
26 |
-
// AMD
|
27 |
-
define( ['jquery', 'datatables.net'], function ( $ ) {
|
28 |
-
return factory( $, window, document );
|
29 |
-
} );
|
30 |
-
}
|
31 |
-
else if ( typeof exports === 'object' ) {
|
32 |
-
// CommonJS
|
33 |
-
module.exports = function (root, $) {
|
34 |
-
if ( ! root ) {
|
35 |
-
root = window;
|
36 |
-
}
|
37 |
-
|
38 |
-
if ( ! $ || ! $.fn.dataTable ) {
|
39 |
-
$ = require('datatables.net')(root, $).$;
|
40 |
-
}
|
41 |
-
|
42 |
-
return factory( $, root, root.document );
|
43 |
-
};
|
44 |
-
}
|
45 |
-
else {
|
46 |
-
// Browser
|
47 |
-
factory( jQuery, window, document );
|
48 |
-
}
|
49 |
-
}(function( $, window, document, undefined ) {
|
50 |
-
'use strict';
|
51 |
-
var DataTable = $.fn.dataTable;
|
52 |
-
|
53 |
-
|
54 |
-
/**
|
55 |
-
* Scroller is a virtual rendering plug-in for DataTables which allows large
|
56 |
-
* datasets to be drawn on screen every quickly. What the virtual rendering means
|
57 |
-
* is that only the visible portion of the table (and a bit to either side to make
|
58 |
-
* the scrolling smooth) is drawn, while the scrolling container gives the
|
59 |
-
* visual impression that the whole table is visible. This is done by making use
|
60 |
-
* of the pagination abilities of DataTables and moving the table around in the
|
61 |
-
* scrolling container DataTables adds to the page. The scrolling container is
|
62 |
-
* forced to the height it would be for the full table display using an extra
|
63 |
-
* element.
|
64 |
-
*
|
65 |
-
* Note that rows in the table MUST all be the same height. Information in a cell
|
66 |
-
* which expands on to multiple lines will cause some odd behaviour in the scrolling.
|
67 |
-
*
|
68 |
-
* Scroller is initialised by simply including the letter 'S' in the sDom for the
|
69 |
-
* table you want to have this feature enabled on. Note that the 'S' must come
|
70 |
-
* AFTER the 't' parameter in `dom`.
|
71 |
-
*
|
72 |
-
* Key features include:
|
73 |
-
* <ul class="limit_length">
|
74 |
-
* <li>Speed! The aim of Scroller for DataTables is to make rendering large data sets fast</li>
|
75 |
-
* <li>Full compatibility with deferred rendering in DataTables for maximum speed</li>
|
76 |
-
* <li>Display millions of rows</li>
|
77 |
-
* <li>Integration with state saving in DataTables (scrolling position is saved)</li>
|
78 |
-
* <li>Easy to use</li>
|
79 |
-
* </ul>
|
80 |
-
*
|
81 |
-
* @class
|
82 |
-
* @constructor
|
83 |
-
* @global
|
84 |
-
* @param {object} dt DataTables settings object or API instance
|
85 |
-
* @param {object} [opts={}] Configuration object for FixedColumns. Options
|
86 |
-
* are defined by {@link Scroller.defaults}
|
87 |
-
*
|
88 |
-
* @requires jQuery 1.7+
|
89 |
-
* @requires DataTables 1.10.0+
|
90 |
-
*
|
91 |
-
* @example
|
92 |
-
* $(document).ready(function() {
|
93 |
-
* $('#example').DataTable( {
|
94 |
-
* "scrollY": "200px",
|
95 |
-
* "ajax": "media/dataset/large.txt",
|
96 |
-
* "dom": "frtiS",
|
97 |
-
* "deferRender": true
|
98 |
-
* } );
|
99 |
-
* } );
|
100 |
-
*/
|
101 |
-
var Scroller = function ( dt, opts ) {
|
102 |
-
/* Sanity check - you just know it will happen */
|
103 |
-
if ( ! (this instanceof Scroller) ) {
|
104 |
-
alert( "Scroller warning: Scroller must be initialised with the 'new' keyword." );
|
105 |
-
return;
|
106 |
-
}
|
107 |
-
|
108 |
-
if ( opts === undefined ) {
|
109 |
-
opts = {};
|
110 |
-
}
|
111 |
-
|
112 |
-
/**
|
113 |
-
* Settings object which contains customisable information for the Scroller instance
|
114 |
-
* @namespace
|
115 |
-
* @private
|
116 |
-
* @extends Scroller.defaults
|
117 |
-
*/
|
118 |
-
this.s = {
|
119 |
-
/**
|
120 |
-
* DataTables settings object
|
121 |
-
* @type object
|
122 |
-
* @default Passed in as first parameter to constructor
|
123 |
-
*/
|
124 |
-
"dt": $.fn.dataTable.Api( dt ).settings()[0],
|
125 |
-
|
126 |
-
/**
|
127 |
-
* Pixel location of the top of the drawn table in the viewport
|
128 |
-
* @type int
|
129 |
-
* @default 0
|
130 |
-
*/
|
131 |
-
"tableTop": 0,
|
132 |
-
|
133 |
-
/**
|
134 |
-
* Pixel location of the bottom of the drawn table in the viewport
|
135 |
-
* @type int
|
136 |
-
* @default 0
|
137 |
-
*/
|
138 |
-
"tableBottom": 0,
|
139 |
-
|
140 |
-
/**
|
141 |
-
* Pixel location of the boundary for when the next data set should be loaded and drawn
|
142 |
-
* when scrolling up the way.
|
143 |
-
* @type int
|
144 |
-
* @default 0
|
145 |
-
* @private
|
146 |
-
*/
|
147 |
-
"redrawTop": 0,
|
148 |
-
|
149 |
-
/**
|
150 |
-
* Pixel location of the boundary for when the next data set should be loaded and drawn
|
151 |
-
* when scrolling down the way. Note that this is actually calculated as the offset from
|
152 |
-
* the top.
|
153 |
-
* @type int
|
154 |
-
* @default 0
|
155 |
-
* @private
|
156 |
-
*/
|
157 |
-
"redrawBottom": 0,
|
158 |
-
|
159 |
-
/**
|
160 |
-
* Auto row height or not indicator
|
161 |
-
* @type bool
|
162 |
-
* @default 0
|
163 |
-
*/
|
164 |
-
"autoHeight": true,
|
165 |
-
|
166 |
-
/**
|
167 |
-
* Number of rows calculated as visible in the visible viewport
|
168 |
-
* @type int
|
169 |
-
* @default 0
|
170 |
-
*/
|
171 |
-
"viewportRows": 0,
|
172 |
-
|
173 |
-
/**
|
174 |
-
* setTimeout reference for state saving, used when state saving is enabled in the DataTable
|
175 |
-
* and when the user scrolls the viewport in order to stop the cookie set taking too much
|
176 |
-
* CPU!
|
177 |
-
* @type int
|
178 |
-
* @default 0
|
179 |
-
*/
|
180 |
-
"stateTO": null,
|
181 |
-
|
182 |
-
/**
|
183 |
-
* setTimeout reference for the redraw, used when server-side processing is enabled in the
|
184 |
-
* DataTables in order to prevent DoSing the server
|
185 |
-
* @type int
|
186 |
-
* @default null
|
187 |
-
*/
|
188 |
-
"drawTO": null,
|
189 |
-
|
190 |
-
heights: {
|
191 |
-
jump: null,
|
192 |
-
page: null,
|
193 |
-
virtual: null,
|
194 |
-
scroll: null,
|
195 |
-
|
196 |
-
/**
|
197 |
-
* Height of rows in the table
|
198 |
-
* @type int
|
199 |
-
* @default 0
|
200 |
-
*/
|
201 |
-
row: null,
|
202 |
-
|
203 |
-
/**
|
204 |
-
* Pixel height of the viewport
|
205 |
-
* @type int
|
206 |
-
* @default 0
|
207 |
-
*/
|
208 |
-
viewport: null
|
209 |
-
},
|
210 |
-
|
211 |
-
topRowFloat: 0,
|
212 |
-
scrollDrawDiff: null,
|
213 |
-
loaderVisible: false
|
214 |
-
};
|
215 |
-
|
216 |
-
// @todo The defaults should extend a `c` property and the internal settings
|
217 |
-
// only held in the `s` property. At the moment they are mixed
|
218 |
-
this.s = $.extend( this.s, Scroller.oDefaults, opts );
|
219 |
-
|
220 |
-
// Workaround for row height being read from height object (see above comment)
|
221 |
-
this.s.heights.row = this.s.rowHeight;
|
222 |
-
|
223 |
-
/**
|
224 |
-
* DOM elements used by the class instance
|
225 |
-
* @private
|
226 |
-
* @namespace
|
227 |
-
*
|
228 |
-
*/
|
229 |
-
this.dom = {
|
230 |
-
"force": document.createElement('div'),
|
231 |
-
"scroller": null,
|
232 |
-
"table": null,
|
233 |
-
"loader": null
|
234 |
-
};
|
235 |
-
|
236 |
-
// Attach the instance to the DataTables instance so it can be accessed in
|
237 |
-
// future. Don't initialise Scroller twice on the same table
|
238 |
-
if ( this.s.dt.oScroller ) {
|
239 |
-
return;
|
240 |
-
}
|
241 |
-
|
242 |
-
this.s.dt.oScroller = this;
|
243 |
-
|
244 |
-
/* Let's do it */
|
245 |
-
this._fnConstruct();
|
246 |
-
};
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
$.extend( Scroller.prototype, {
|
251 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
252 |
-
* Public methods
|
253 |
-
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
254 |
-
|
255 |
-
/**
|
256 |
-
* Calculate the pixel position from the top of the scrolling container for
|
257 |
-
* a given row
|
258 |
-
* @param {int} iRow Row number to calculate the position of
|
259 |
-
* @returns {int} Pixels
|
260 |
-
* @example
|
261 |
-
* $(document).ready(function() {
|
262 |
-
* $('#example').dataTable( {
|
263 |
-
* "sScrollY": "200px",
|
264 |
-
* "sAjaxSource": "media/dataset/large.txt",
|
265 |
-
* "sDom": "frtiS",
|
266 |
-
* "bDeferRender": true,
|
267 |
-
* "fnInitComplete": function (o) {
|
268 |
-
* // Find where row 25 is
|
269 |
-
* alert( o.oScroller.fnRowToPixels( 25 ) );
|
270 |
-
* }
|
271 |
-
* } );
|
272 |
-
* } );
|
273 |
-
*/
|
274 |
-
"fnRowToPixels": function ( rowIdx, intParse, virtual )
|
275 |
-
{
|
276 |
-
var pixels;
|
277 |
-
|
278 |
-
if ( virtual ) {
|
279 |
-
pixels = this._domain( 'virtualToPhysical', rowIdx * this.s.heights.row );
|
280 |
-
}
|
281 |
-
else {
|
282 |
-
var diff = rowIdx - this.s.baseRowTop;
|
283 |
-
pixels = this.s.baseScrollTop + (diff * this.s.heights.row);
|
284 |
-
}
|
285 |
-
|
286 |
-
return intParse || intParse === undefined ?
|
287 |
-
parseInt( pixels, 10 ) :
|
288 |
-
pixels;
|
289 |
-
},
|
290 |
-
|
291 |
-
|
292 |
-
/**
|
293 |
-
* Calculate the row number that will be found at the given pixel position
|
294 |
-
* (y-scroll).
|
295 |
-
*
|
296 |
-
* Please note that when the height of the full table exceeds 1 million
|
297 |
-
* pixels, Scroller switches into a non-linear mode for the scrollbar to fit
|
298 |
-
* all of the records into a finite area, but this function returns a linear
|
299 |
-
* value (relative to the last non-linear positioning).
|
300 |
-
* @param {int} iPixels Offset from top to calculate the row number of
|
301 |
-
* @param {int} [intParse=true] If an integer value should be returned
|
302 |
-
* @param {int} [virtual=false] Perform the calculations in the virtual domain
|
303 |
-
* @returns {int} Row index
|
304 |
-
* @example
|
305 |
-
* $(document).ready(function() {
|
306 |
-
* $('#example').dataTable( {
|
307 |
-
* "sScrollY": "200px",
|
308 |
-
* "sAjaxSource": "media/dataset/large.txt",
|
309 |
-
* "sDom": "frtiS",
|
310 |
-
* "bDeferRender": true,
|
311 |
-
* "fnInitComplete": function (o) {
|
312 |
-
* // Find what row number is at 500px
|
313 |
-
* alert( o.oScroller.fnPixelsToRow( 500 ) );
|
314 |
-
* }
|
315 |
-
* } );
|
316 |
-
* } );
|
317 |
-
*/
|
318 |
-
"fnPixelsToRow": function ( pixels, intParse, virtual )
|
319 |
-
{
|
320 |
-
var diff = pixels - this.s.baseScrollTop;
|
321 |
-
var row = virtual ?
|
322 |
-
this._domain( 'physicalToVirtual', pixels ) / this.s.heights.row :
|
323 |
-
( diff / this.s.heights.row ) + this.s.baseRowTop;
|
324 |
-
|
325 |
-
return intParse || intParse === undefined ?
|
326 |
-
parseInt( row, 10 ) :
|
327 |
-
row;
|
328 |
-
},
|
329 |
-
|
330 |
-
|
331 |
-
/**
|
332 |
-
* Calculate the row number that will be found at the given pixel position (y-scroll)
|
333 |
-
* @param {int} iRow Row index to scroll to
|
334 |
-
* @param {bool} [bAnimate=true] Animate the transition or not
|
335 |
-
* @returns {void}
|
336 |
-
* @example
|
337 |
-
* $(document).ready(function() {
|
338 |
-
* $('#example').dataTable( {
|
339 |
-
* "sScrollY": "200px",
|
340 |
-
* "sAjaxSource": "media/dataset/large.txt",
|
341 |
-
* "sDom": "frtiS",
|
342 |
-
* "bDeferRender": true,
|
343 |
-
* "fnInitComplete": function (o) {
|
344 |
-
* // Immediately scroll to row 1000
|
345 |
-
* o.oScroller.fnScrollToRow( 1000 );
|
346 |
-
* }
|
347 |
-
* } );
|
348 |
-
*
|
349 |
-
* // Sometime later on use the following to scroll to row 500...
|
350 |
-
* var oSettings = $('#example').dataTable().fnSettings();
|
351 |
-
* oSettings.oScroller.fnScrollToRow( 500 );
|
352 |
-
* } );
|
353 |
-
*/
|
354 |
-
"fnScrollToRow": function ( iRow, bAnimate )
|
355 |
-
{
|
356 |
-
var that = this;
|
357 |
-
var ani = false;
|
358 |
-
var px = this.fnRowToPixels( iRow );
|
359 |
-
|
360 |
-
// We need to know if the table will redraw or not before doing the
|
361 |
-
// scroll. If it will not redraw, then we need to use the currently
|
362 |
-
// displayed table, and scroll with the physical pixels. Otherwise, we
|
363 |
-
// need to calculate the table's new position from the virtual
|
364 |
-
// transform.
|
365 |
-
var preRows = ((this.s.displayBuffer-1)/2) * this.s.viewportRows;
|
366 |
-
var drawRow = iRow - preRows;
|
367 |
-
if ( drawRow < 0 ) {
|
368 |
-
drawRow = 0;
|
369 |
-
}
|
370 |
-
|
371 |
-
if ( (px > this.s.redrawBottom || px < this.s.redrawTop) && this.s.dt._iDisplayStart !== drawRow ) {
|
372 |
-
ani = true;
|
373 |
-
px = this.fnRowToPixels( iRow, false, true );
|
374 |
-
}
|
375 |
-
|
376 |
-
if ( typeof bAnimate == 'undefined' || bAnimate )
|
377 |
-
{
|
378 |
-
this.s.ani = ani;
|
379 |
-
$(this.dom.scroller).animate( {
|
380 |
-
"scrollTop": px
|
381 |
-
}, function () {
|
382 |
-
// This needs to happen after the animation has completed and
|
383 |
-
// the final scroll event fired
|
384 |
-
setTimeout( function () {
|
385 |
-
that.s.ani = false;
|
386 |
-
}, 25 );
|
387 |
-
} );
|
388 |
-
}
|
389 |
-
else
|
390 |
-
{
|
391 |
-
$(this.dom.scroller).scrollTop( px );
|
392 |
-
}
|
393 |
-
},
|
394 |
-
|
395 |
-
|
396 |
-
/**
|
397 |
-
* Calculate and store information about how many rows are to be displayed
|
398 |
-
* in the scrolling viewport, based on current dimensions in the browser's
|
399 |
-
* rendering. This can be particularly useful if the table is initially
|
400 |
-
* drawn in a hidden element - for example in a tab.
|
401 |
-
* @param {bool} [bRedraw=true] Redraw the table automatically after the recalculation, with
|
402 |
-
* the new dimensions forming the basis for the draw.
|
403 |
-
* @returns {void}
|
404 |
-
* @example
|
405 |
-
* $(document).ready(function() {
|
406 |
-
* // Make the example container hidden to throw off the browser's sizing
|
407 |
-
* document.getElementById('container').style.display = "none";
|
408 |
-
* var oTable = $('#example').dataTable( {
|
409 |
-
* "sScrollY": "200px",
|
410 |
-
* "sAjaxSource": "media/dataset/large.txt",
|
411 |
-
* "sDom": "frtiS",
|
412 |
-
* "bDeferRender": true,
|
413 |
-
* "fnInitComplete": function (o) {
|
414 |
-
* // Immediately scroll to row 1000
|
415 |
-
* o.oScroller.fnScrollToRow( 1000 );
|
416 |
-
* }
|
417 |
-
* } );
|
418 |
-
*
|
419 |
-
* setTimeout( function () {
|
420 |
-
* // Make the example container visible and recalculate the scroller sizes
|
421 |
-
* document.getElementById('container').style.display = "block";
|
422 |
-
* oTable.fnSettings().oScroller.fnMeasure();
|
423 |
-
* }, 3000 );
|
424 |
-
*/
|
425 |
-
"fnMeasure": function ( bRedraw )
|
426 |
-
{
|
427 |
-
if ( this.s.autoHeight )
|
428 |
-
{
|
429 |
-
this._fnCalcRowHeight();
|
430 |
-
}
|
431 |
-
|
432 |
-
var heights = this.s.heights;
|
433 |
-
|
434 |
-
if ( heights.row ) {
|
435 |
-
heights.viewport = $(this.dom.scroller).height();
|
436 |
-
this.s.viewportRows = parseInt( heights.viewport / heights.row, 10 )+1;
|
437 |
-
this.s.dt._iDisplayLength = this.s.viewportRows * this.s.displayBuffer;
|
438 |
-
}
|
439 |
-
|
440 |
-
if ( bRedraw === undefined || bRedraw )
|
441 |
-
{
|
442 |
-
this.s.dt.oInstance.fnDraw( false );
|
443 |
-
}
|
444 |
-
},
|
445 |
-
|
446 |
-
|
447 |
-
/**
|
448 |
-
* Get information about current displayed record range. This corresponds to
|
449 |
-
* the information usually displayed in the "Info" block of the table.
|
450 |
-
*
|
451 |
-
* @returns {object} info as an object:
|
452 |
-
* {
|
453 |
-
* start: {int}, // the 0-indexed record at the top of the viewport
|
454 |
-
* end: {int}, // the 0-indexed record at the bottom of the viewport
|
455 |
-
* }
|
456 |
-
*/
|
457 |
-
"fnPageInfo": function()
|
458 |
-
{
|
459 |
-
var
|
460 |
-
dt = this.s.dt,
|
461 |
-
iScrollTop = this.dom.scroller.scrollTop,
|
462 |
-
iTotal = dt.fnRecordsDisplay(),
|
463 |
-
iPossibleEnd = Math.ceil(this.fnPixelsToRow(iScrollTop + this.s.heights.viewport, false, this.s.ani));
|
464 |
-
|
465 |
-
return {
|
466 |
-
start: Math.floor(this.fnPixelsToRow(iScrollTop, false, this.s.ani)),
|
467 |
-
end: iTotal < iPossibleEnd ? iTotal-1 : iPossibleEnd-1
|
468 |
-
};
|
469 |
-
},
|
470 |
-
|
471 |
-
|
472 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
473 |
-
* Private methods (they are of course public in JS, but recommended as private)
|
474 |
-
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
475 |
-
|
476 |
-
/**
|
477 |
-
* Initialisation for Scroller
|
478 |
-
* @returns {void}
|
479 |
-
* @private
|
480 |
-
*/
|
481 |
-
"_fnConstruct": function ()
|
482 |
-
{
|
483 |
-
var that = this;
|
484 |
-
|
485 |
-
/* Sanity check */
|
486 |
-
if ( !this.s.dt.oFeatures.bPaginate ) {
|
487 |
-
this.s.dt.oApi._fnLog( this.s.dt, 0, 'Pagination must be enabled for Scroller' );
|
488 |
-
return;
|
489 |
-
}
|
490 |
-
|
491 |
-
/* Insert a div element that we can use to force the DT scrolling container to
|
492 |
-
* the height that would be required if the whole table was being displayed
|
493 |
-
*/
|
494 |
-
this.dom.force.style.position = "relative";
|
495 |
-
this.dom.force.style.top = "0px";
|
496 |
-
this.dom.force.style.left = "0px";
|
497 |
-
this.dom.force.style.width = "1px";
|
498 |
-
|
499 |
-
this.dom.scroller = $('div.'+this.s.dt.oClasses.sScrollBody, this.s.dt.nTableWrapper)[0];
|
500 |
-
this.dom.scroller.appendChild( this.dom.force );
|
501 |
-
this.dom.scroller.style.position = "relative";
|
502 |
-
|
503 |
-
this.dom.table = $('>table', this.dom.scroller)[0];
|
504 |
-
this.dom.table.style.position = "absolute";
|
505 |
-
this.dom.table.style.top = "0px";
|
506 |
-
this.dom.table.style.left = "0px";
|
507 |
-
|
508 |
-
// Add class to 'announce' that we are a Scroller table
|
509 |
-
$(this.s.dt.nTableWrapper).addClass('DTS');
|
510 |
-
|
511 |
-
// Add a 'loading' indicator
|
512 |
-
if ( this.s.loadingIndicator )
|
513 |
-
{
|
514 |
-
this.dom.loader = $('<div class="dataTables_processing DTS_Loading">'+this.s.dt.oLanguage.sLoadingRecords+'</div>')
|
515 |
-
.css('display', 'none');
|
516 |
-
|
517 |
-
$(this.dom.scroller.parentNode)
|
518 |
-
.css('position', 'relative')
|
519 |
-
.append( this.dom.loader );
|
520 |
-
}
|
521 |
-
|
522 |
-
/* Initial size calculations */
|
523 |
-
if ( this.s.heights.row && this.s.heights.row != 'auto' )
|
524 |
-
{
|
525 |
-
this.s.autoHeight = false;
|
526 |
-
}
|
527 |
-
this.fnMeasure( false );
|
528 |
-
|
529 |
-
/* Scrolling callback to see if a page change is needed - use a throttled
|
530 |
-
* function for the save save callback so we aren't hitting it on every
|
531 |
-
* scroll
|
532 |
-
*/
|
533 |
-
this.s.ingnoreScroll = true;
|
534 |
-
this.s.stateSaveThrottle = this.s.dt.oApi._fnThrottle( function () {
|
535 |
-
that.s.dt.oApi._fnSaveState( that.s.dt );
|
536 |
-
}, 500 );
|
537 |
-
$(this.dom.scroller).on( 'scroll.DTS', function (e) {
|
538 |
-
that._fnScroll.call( that );
|
539 |
-
} );
|
540 |
-
|
541 |
-
/* In iOS we catch the touchstart event in case the user tries to scroll
|
542 |
-
* while the display is already scrolling
|
543 |
-
*/
|
544 |
-
$(this.dom.scroller).on('touchstart.DTS', function () {
|
545 |
-
that._fnScroll.call( that );
|
546 |
-
} );
|
547 |
-
|
548 |
-
/* Update the scroller when the DataTable is redrawn */
|
549 |
-
this.s.dt.aoDrawCallback.push( {
|
550 |
-
"fn": function () {
|
551 |
-
if ( that.s.dt.bInitialised ) {
|
552 |
-
that._fnDrawCallback.call( that );
|
553 |
-
}
|
554 |
-
},
|
555 |
-
"sName": "Scroller"
|
556 |
-
} );
|
557 |
-
|
558 |
-
/* On resize, update the information element, since the number of rows shown might change */
|
559 |
-
$(window).on( 'resize.DTS', function () {
|
560 |
-
that.fnMeasure( false );
|
561 |
-
that._fnInfo();
|
562 |
-
} );
|
563 |
-
|
564 |
-
/* Add a state saving parameter to the DT state saving so we can restore the exact
|
565 |
-
* position of the scrolling
|
566 |
-
*/
|
567 |
-
var initialStateSave = true;
|
568 |
-
this.s.dt.oApi._fnCallbackReg( this.s.dt, 'aoStateSaveParams', function (oS, oData) {
|
569 |
-
/* Set iScroller to saved scroll position on initialization.
|
570 |
-
*/
|
571 |
-
if(initialStateSave && that.s.dt.oLoadedState){
|
572 |
-
oData.iScroller = that.s.dt.oLoadedState.iScroller;
|
573 |
-
oData.iScrollerTopRow = that.s.dt.oLoadedState.iScrollerTopRow;
|
574 |
-
initialStateSave = false;
|
575 |
-
} else {
|
576 |
-
oData.iScroller = that.dom.scroller.scrollTop;
|
577 |
-
oData.iScrollerTopRow = that.s.topRowFloat;
|
578 |
-
}
|
579 |
-
}, "Scroller_State" );
|
580 |
-
|
581 |
-
if ( this.s.dt.oLoadedState ) {
|
582 |
-
this.s.topRowFloat = this.s.dt.oLoadedState.iScrollerTopRow || 0;
|
583 |
-
}
|
584 |
-
|
585 |
-
// Measure immediately. Scroller will have been added using preInit, so
|
586 |
-
// we can reliably do this here. We could potentially also measure on
|
587 |
-
// init complete, which would be useful for cases where the data is Ajax
|
588 |
-
// loaded and longer than a single line.
|
589 |
-
$(this.s.dt.nTable).one( 'init.dt', function () {
|
590 |
-
that.fnMeasure();
|
591 |
-
} );
|
592 |
-
|
593 |
-
/* Destructor */
|
594 |
-
this.s.dt.aoDestroyCallback.push( {
|
595 |
-
"sName": "Scroller",
|
596 |
-
"fn": function () {
|
597 |
-
$(window).off( 'resize.DTS' );
|
598 |
-
$(that.dom.scroller).off('touchstart.DTS scroll.DTS');
|
599 |
-
$(that.s.dt.nTableWrapper).removeClass('DTS');
|
600 |
-
$('div.DTS_Loading', that.dom.scroller.parentNode).remove();
|
601 |
-
$(that.s.dt.nTable).off( 'init.dt' );
|
602 |
-
|
603 |
-
that.dom.table.style.position = "";
|
604 |
-
that.dom.table.style.top = "";
|
605 |
-
that.dom.table.style.left = "";
|
606 |
-
}
|
607 |
-
} );
|
608 |
-
},
|
609 |
-
|
610 |
-
|
611 |
-
/**
|
612 |
-
* Scrolling function - fired whenever the scrolling position is changed.
|
613 |
-
* This method needs to use the stored values to see if the table should be
|
614 |
-
* redrawn as we are moving towards the end of the information that is
|
615 |
-
* currently drawn or not. If needed, then it will redraw the table based on
|
616 |
-
* the new position.
|
617 |
-
* @returns {void}
|
618 |
-
* @private
|
619 |
-
*/
|
620 |
-
"_fnScroll": function ()
|
621 |
-
{
|
622 |
-
var
|
623 |
-
that = this,
|
624 |
-
heights = this.s.heights,
|
625 |
-
iScrollTop = this.dom.scroller.scrollTop,
|
626 |
-
iTopRow;
|
627 |
-
|
628 |
-
if ( this.s.skip ) {
|
629 |
-
return;
|
630 |
-
}
|
631 |
-
|
632 |
-
if ( this.s.ingnoreScroll ) {
|
633 |
-
return;
|
634 |
-
}
|
635 |
-
|
636 |
-
/* If the table has been sorted or filtered, then we use the redraw that
|
637 |
-
* DataTables as done, rather than performing our own
|
638 |
-
*/
|
639 |
-
if ( this.s.dt.bFiltered || this.s.dt.bSorted ) {
|
640 |
-
this.s.lastScrollTop = 0;
|
641 |
-
return;
|
642 |
-
}
|
643 |
-
|
644 |
-
/* Update the table's information display for what is now in the viewport */
|
645 |
-
this._fnInfo();
|
646 |
-
|
647 |
-
/* We don't want to state save on every scroll event - that's heavy
|
648 |
-
* handed, so use a timeout to update the state saving only when the
|
649 |
-
* scrolling has finished
|
650 |
-
*/
|
651 |
-
clearTimeout( this.s.stateTO );
|
652 |
-
this.s.stateTO = setTimeout( function () {
|
653 |
-
that.s.dt.oApi._fnSaveState( that.s.dt );
|
654 |
-
}, 250 );
|
655 |
-
|
656 |
-
/* Check if the scroll point is outside the trigger boundary which would required
|
657 |
-
* a DataTables redraw
|
658 |
-
*/
|
659 |
-
if ( iScrollTop < this.s.redrawTop || iScrollTop > this.s.redrawBottom ) {
|
660 |
-
var preRows = Math.ceil( ((this.s.displayBuffer-1)/2) * this.s.viewportRows );
|
661 |
-
|
662 |
-
if ( Math.abs( iScrollTop - this.s.lastScrollTop ) > heights.viewport || this.s.ani ) {
|
663 |
-
iTopRow = parseInt(this._domain( 'physicalToVirtual', iScrollTop ) / heights.row, 10) - preRows;
|
664 |
-
this.s.topRowFloat = this._domain( 'physicalToVirtual', iScrollTop ) / heights.row;
|
665 |
-
}
|
666 |
-
else {
|
667 |
-
iTopRow = this.fnPixelsToRow( iScrollTop ) - preRows;
|
668 |
-
this.s.topRowFloat = this.fnPixelsToRow( iScrollTop, false );
|
669 |
-
}
|
670 |
-
|
671 |
-
if ( iTopRow <= 0 ) {
|
672 |
-
/* At the start of the table */
|
673 |
-
iTopRow = 0;
|
674 |
-
}
|
675 |
-
else if ( iTopRow + this.s.dt._iDisplayLength > this.s.dt.fnRecordsDisplay() ) {
|
676 |
-
/* At the end of the table */
|
677 |
-
iTopRow = this.s.dt.fnRecordsDisplay() - this.s.dt._iDisplayLength;
|
678 |
-
if ( iTopRow < 0 ) {
|
679 |
-
iTopRow = 0;
|
680 |
-
}
|
681 |
-
}
|
682 |
-
else if ( iTopRow % 2 !== 0 ) {
|
683 |
-
// For the row-striping classes (odd/even) we want only to start
|
684 |
-
// on evens otherwise the stripes will change between draws and
|
685 |
-
// look rubbish
|
686 |
-
iTopRow++;
|
687 |
-
}
|
688 |
-
|
689 |
-
if ( iTopRow != this.s.dt._iDisplayStart ) {
|
690 |
-
/* Cache the new table position for quick lookups */
|
691 |
-
this.s.tableTop = $(this.s.dt.nTable).offset().top;
|
692 |
-
this.s.tableBottom = $(this.s.dt.nTable).height() + this.s.tableTop;
|
693 |
-
|
694 |
-
var draw = function () {
|
695 |
-
if ( that.s.scrollDrawReq === null ) {
|
696 |
-
that.s.scrollDrawReq = iScrollTop;
|
697 |
-
}
|
698 |
-
|
699 |
-
that.s.dt._iDisplayStart = iTopRow;
|
700 |
-
that.s.dt.oApi._fnDraw( that.s.dt );
|
701 |
-
};
|
702 |
-
|
703 |
-
/* Do the DataTables redraw based on the calculated start point - note that when
|
704 |
-
* using server-side processing we introduce a small delay to not DoS the server...
|
705 |
-
*/
|
706 |
-
if ( this.s.dt.oFeatures.bServerSide ) {
|
707 |
-
clearTimeout( this.s.drawTO );
|
708 |
-
this.s.drawTO = setTimeout( draw, this.s.serverWait );
|
709 |
-
}
|
710 |
-
else {
|
711 |
-
draw();
|
712 |
-
}
|
713 |
-
|
714 |
-
if ( this.dom.loader && ! this.s.loaderVisible ) {
|
715 |
-
this.dom.loader.css( 'display', 'block' );
|
716 |
-
this.s.loaderVisible = true;
|
717 |
-
}
|
718 |
-
}
|
719 |
-
}
|
720 |
-
else {
|
721 |
-
this.s.topRowFloat = this._domain( 'physicalToVirtual', iScrollTop ) / heights.row;
|
722 |
-
}
|
723 |
-
|
724 |
-
this.s.lastScrollTop = iScrollTop;
|
725 |
-
this.s.stateSaveThrottle();
|
726 |
-
},
|
727 |
-
|
728 |
-
|
729 |
-
/**
|
730 |
-
* Convert from one domain to another. The physical domain is the actual
|
731 |
-
* pixel count on the screen, while the virtual is if we had browsers which
|
732 |
-
* had scrolling containers of infinite height (i.e. the absolute value)
|
733 |
-
*
|
734 |
-
* @param {string} dir Domain transform direction, `virtualToPhysical` or
|
735 |
-
* `physicalToVirtual`
|
736 |
-
* @returns {number} Calculated transform
|
737 |
-
* @private
|
738 |
-
*/
|
739 |
-
_domain: function ( dir, val )
|
740 |
-
{
|
741 |
-
var heights = this.s.heights;
|
742 |
-
var coeff;
|
743 |
-
|
744 |
-
// If the virtual and physical height match, then we use a linear
|
745 |
-
// transform between the two, allowing the scrollbar to be linear
|
746 |
-
if ( heights.virtual === heights.scroll ) {
|
747 |
-
return val;
|
748 |
-
}
|
749 |
-
|
750 |
-
// Otherwise, we want a non-linear scrollbar to take account of the
|
751 |
-
// redrawing regions at the start and end of the table, otherwise these
|
752 |
-
// can stutter badly - on large tables 30px (for example) scroll might
|
753 |
-
// be hundreds of rows, so the table would be redrawing every few px at
|
754 |
-
// the start and end. Use a simple quadratic to stop this. It does mean
|
755 |
-
// the scrollbar is non-linear, but with such massive data sets, the
|
756 |
-
// scrollbar is going to be a best guess anyway
|
757 |
-
var xMax = (heights.scroll - heights.viewport) / 2;
|
758 |
-
var yMax = (heights.virtual - heights.viewport) / 2;
|
759 |
-
|
760 |
-
coeff = yMax / ( xMax * xMax );
|
761 |
-
|
762 |
-
if ( dir === 'virtualToPhysical' ) {
|
763 |
-
if ( val < yMax ) {
|
764 |
-
return Math.pow(val / coeff, 0.5);
|
765 |
-
}
|
766 |
-
else {
|
767 |
-
val = (yMax*2) - val;
|
768 |
-
return val < 0 ?
|
769 |
-
heights.scroll :
|
770 |
-
(xMax*2) - Math.pow(val / coeff, 0.5);
|
771 |
-
}
|
772 |
-
}
|
773 |
-
else if ( dir === 'physicalToVirtual' ) {
|
774 |
-
if ( val < xMax ) {
|
775 |
-
return val * val * coeff;
|
776 |
-
}
|
777 |
-
else {
|
778 |
-
val = (xMax*2) - val;
|
779 |
-
return val < 0 ?
|
780 |
-
heights.virtual :
|
781 |
-
(yMax*2) - (val * val * coeff);
|
782 |
-
}
|
783 |
-
}
|
784 |
-
},
|
785 |
-
|
786 |
-
|
787 |
-
/**
|
788 |
-
* Draw callback function which is fired when the DataTable is redrawn. The main function of
|
789 |
-
* this method is to position the drawn table correctly the scrolling container for the rows
|
790 |
-
* that is displays as a result of the scrolling position.
|
791 |
-
* @returns {void}
|
792 |
-
* @private
|
793 |
-
*/
|
794 |
-
"_fnDrawCallback": function ()
|
795 |
-
{
|
796 |
-
var
|
797 |
-
that = this,
|
798 |
-
heights = this.s.heights,
|
799 |
-
iScrollTop = this.dom.scroller.scrollTop,
|
800 |
-
iActualScrollTop = iScrollTop,
|
801 |
-
iScrollBottom = iScrollTop + heights.viewport,
|
802 |
-
iTableHeight = $(this.s.dt.nTable).height(),
|
803 |
-
displayStart = this.s.dt._iDisplayStart,
|
804 |
-
displayLen = this.s.dt._iDisplayLength,
|
805 |
-
displayEnd = this.s.dt.fnRecordsDisplay();
|
806 |
-
|
807 |
-
// Disable the scroll event listener while we are updating the DOM
|
808 |
-
this.s.skip = true;
|
809 |
-
|
810 |
-
// Resize the scroll forcing element
|
811 |
-
this._fnScrollForce();
|
812 |
-
|
813 |
-
// Reposition the scrolling for the updated virtual position if needed
|
814 |
-
if ( displayStart === 0 ) {
|
815 |
-
// Linear calculation at the top of the table
|
816 |
-
iScrollTop = this.s.topRowFloat * heights.row;
|
817 |
-
}
|
818 |
-
else if ( displayStart + displayLen >= displayEnd ) {
|
819 |
-
// Linear calculation that the bottom as well
|
820 |
-
iScrollTop = heights.scroll - ((displayEnd - this.s.topRowFloat) * heights.row);
|
821 |
-
}
|
822 |
-
else {
|
823 |
-
// Domain scaled in the middle
|
824 |
-
iScrollTop = this._domain( 'virtualToPhysical', this.s.topRowFloat * heights.row );
|
825 |
-
}
|
826 |
-
|
827 |
-
this.dom.scroller.scrollTop = iScrollTop;
|
828 |
-
|
829 |
-
// Store positional information so positional calculations can be based
|
830 |
-
// upon the current table draw position
|
831 |
-
this.s.baseScrollTop = iScrollTop;
|
832 |
-
this.s.baseRowTop = this.s.topRowFloat;
|
833 |
-
|
834 |
-
// Position the table in the virtual scroller
|
835 |
-
var tableTop = iScrollTop - ((this.s.topRowFloat - displayStart) * heights.row);
|
836 |
-
if ( displayStart === 0 ) {
|
837 |
-
tableTop = 0;
|
838 |
-
}
|
839 |
-
else if ( displayStart + displayLen >= displayEnd ) {
|
840 |
-
tableTop = heights.scroll - iTableHeight;
|
841 |
-
}
|
842 |
-
|
843 |
-
this.dom.table.style.top = tableTop+'px';
|
844 |
-
|
845 |
-
/* Cache some information for the scroller */
|
846 |
-
this.s.tableTop = tableTop;
|
847 |
-
this.s.tableBottom = iTableHeight + this.s.tableTop;
|
848 |
-
|
849 |
-
// Calculate the boundaries for where a redraw will be triggered by the
|
850 |
-
// scroll event listener
|
851 |
-
var boundaryPx = (iScrollTop - this.s.tableTop) * this.s.boundaryScale;
|
852 |
-
this.s.redrawTop = iScrollTop - boundaryPx;
|
853 |
-
this.s.redrawBottom = iScrollTop + boundaryPx;
|
854 |
-
|
855 |
-
this.s.skip = false;
|
856 |
-
|
857 |
-
// Restore the scrolling position that was saved by DataTable's state
|
858 |
-
// saving Note that this is done on the second draw when data is Ajax
|
859 |
-
// sourced, and the first draw when DOM soured
|
860 |
-
if ( this.s.dt.oFeatures.bStateSave && this.s.dt.oLoadedState !== null &&
|
861 |
-
typeof this.s.dt.oLoadedState.iScroller != 'undefined' )
|
862 |
-
{
|
863 |
-
// A quirk of DataTables is that the draw callback will occur on an
|
864 |
-
// empty set if Ajax sourced, but not if server-side processing.
|
865 |
-
var ajaxSourced = (this.s.dt.sAjaxSource || that.s.dt.ajax) && ! this.s.dt.oFeatures.bServerSide ?
|
866 |
-
true :
|
867 |
-
false;
|
868 |
-
|
869 |
-
if ( ( ajaxSourced && this.s.dt.iDraw == 2) ||
|
870 |
-
(!ajaxSourced && this.s.dt.iDraw == 1) )
|
871 |
-
{
|
872 |
-
setTimeout( function () {
|
873 |
-
$(that.dom.scroller).scrollTop( that.s.dt.oLoadedState.iScroller );
|
874 |
-
that.s.redrawTop = that.s.dt.oLoadedState.iScroller - (heights.viewport/2);
|
875 |
-
|
876 |
-
// In order to prevent layout thrashing we need another
|
877 |
-
// small delay
|
878 |
-
setTimeout( function () {
|
879 |
-
that.s.ingnoreScroll = false;
|
880 |
-
}, 0 );
|
881 |
-
}, 0 );
|
882 |
-
}
|
883 |
-
}
|
884 |
-
else {
|
885 |
-
that.s.ingnoreScroll = false;
|
886 |
-
}
|
887 |
-
|
888 |
-
// Because of the order of the DT callbacks, the info update will
|
889 |
-
// take precedence over the one we want here. So a 'thread' break is
|
890 |
-
// needed. Only add the thread break if bInfo is set
|
891 |
-
if ( this.s.dt.oFeatures.bInfo ) {
|
892 |
-
setTimeout( function () {
|
893 |
-
that._fnInfo.call( that );
|
894 |
-
}, 0 );
|
895 |
-
}
|
896 |
-
|
897 |
-
// Hide the loading indicator
|
898 |
-
if ( this.dom.loader && this.s.loaderVisible ) {
|
899 |
-
this.dom.loader.css( 'display', 'none' );
|
900 |
-
this.s.loaderVisible = false;
|
901 |
-
}
|
902 |
-
},
|
903 |
-
|
904 |
-
|
905 |
-
/**
|
906 |
-
* Force the scrolling container to have height beyond that of just the
|
907 |
-
* table that has been drawn so the user can scroll the whole data set.
|
908 |
-
*
|
909 |
-
* Note that if the calculated required scrolling height exceeds a maximum
|
910 |
-
* value (1 million pixels - hard-coded) the forcing element will be set
|
911 |
-
* only to that maximum value and virtual / physical domain transforms will
|
912 |
-
* be used to allow Scroller to display tables of any number of records.
|
913 |
-
* @returns {void}
|
914 |
-
* @private
|
915 |
-
*/
|
916 |
-
_fnScrollForce: function ()
|
917 |
-
{
|
918 |
-
var heights = this.s.heights;
|
919 |
-
var max = 1000000;
|
920 |
-
|
921 |
-
heights.virtual = heights.row * this.s.dt.fnRecordsDisplay();
|
922 |
-
heights.scroll = heights.virtual;
|
923 |
-
|
924 |
-
if ( heights.scroll > max ) {
|
925 |
-
heights.scroll = max;
|
926 |
-
}
|
927 |
-
|
928 |
-
// Minimum height so there is always a row visible (the 'no rows found'
|
929 |
-
// if reduced to zero filtering)
|
930 |
-
this.dom.force.style.height = heights.scroll > this.s.heights.row ?
|
931 |
-
heights.scroll+'px' :
|
932 |
-
this.s.heights.row+'px';
|
933 |
-
},
|
934 |
-
|
935 |
-
|
936 |
-
/**
|
937 |
-
* Automatic calculation of table row height. This is just a little tricky here as using
|
938 |
-
* initialisation DataTables has tale the table out of the document, so we need to create
|
939 |
-
* a new table and insert it into the document, calculate the row height and then whip the
|
940 |
-
* table out.
|
941 |
-
* @returns {void}
|
942 |
-
* @private
|
943 |
-
*/
|
944 |
-
"_fnCalcRowHeight": function ()
|
945 |
-
{
|
946 |
-
var dt = this.s.dt;
|
947 |
-
var origTable = dt.nTable;
|
948 |
-
var nTable = origTable.cloneNode( false );
|
949 |
-
var tbody = $('<tbody/>').appendTo( nTable );
|
950 |
-
var container = $(
|
951 |
-
'<div class="'+dt.oClasses.sWrapper+' DTS">'+
|
952 |
-
'<div class="'+dt.oClasses.sScrollWrapper+'">'+
|
953 |
-
'<div class="'+dt.oClasses.sScrollBody+'"></div>'+
|
954 |
-
'</div>'+
|
955 |
-
'</div>'
|
956 |
-
);
|
957 |
-
|
958 |
-
// Want 3 rows in the sizing table so :first-child and :last-child
|
959 |
-
// CSS styles don't come into play - take the size of the middle row
|
960 |
-
$('tbody tr:lt(4)', origTable).clone().appendTo( tbody );
|
961 |
-
while( $('tr', tbody).length < 3 ) {
|
962 |
-
tbody.append( '<tr><td> </td></tr>' );
|
963 |
-
}
|
964 |
-
|
965 |
-
$('div.'+dt.oClasses.sScrollBody, container).append( nTable );
|
966 |
-
|
967 |
-
// If initialised using `dom`, use the holding element as the insert point
|
968 |
-
var insertEl = this.s.dt.nHolding || origTable.parentNode;
|
969 |
-
|
970 |
-
if ( ! $(insertEl).is(':visible') ) {
|
971 |
-
insertEl = 'body';
|
972 |
-
}
|
973 |
-
|
974 |
-
container.appendTo( insertEl );
|
975 |
-
this.s.heights.row = $('tr', tbody).eq(1).outerHeight();
|
976 |
-
|
977 |
-
container.remove();
|
978 |
-
},
|
979 |
-
|
980 |
-
|
981 |
-
/**
|
982 |
-
* Update any information elements that are controlled by the DataTable based on the scrolling
|
983 |
-
* viewport and what rows are visible in it. This function basically acts in the same way as
|
984 |
-
* _fnUpdateInfo in DataTables, and effectively replaces that function.
|
985 |
-
* @returns {void}
|
986 |
-
* @private
|
987 |
-
*/
|
988 |
-
"_fnInfo": function ()
|
989 |
-
{
|
990 |
-
if ( !this.s.dt.oFeatures.bInfo )
|
991 |
-
{
|
992 |
-
return;
|
993 |
-
}
|
994 |
-
|
995 |
-
var
|
996 |
-
dt = this.s.dt,
|
997 |
-
language = dt.oLanguage,
|
998 |
-
iScrollTop = this.dom.scroller.scrollTop,
|
999 |
-
iStart = Math.floor( this.fnPixelsToRow(iScrollTop, false, this.s.ani)+1 ),
|
1000 |
-
iMax = dt.fnRecordsTotal(),
|
1001 |
-
iTotal = dt.fnRecordsDisplay(),
|
1002 |
-
iPossibleEnd = Math.ceil( this.fnPixelsToRow(iScrollTop+this.s.heights.viewport, false, this.s.ani) ),
|
1003 |
-
iEnd = iTotal < iPossibleEnd ? iTotal : iPossibleEnd,
|
1004 |
-
sStart = dt.fnFormatNumber( iStart ),
|
1005 |
-
sEnd = dt.fnFormatNumber( iEnd ),
|
1006 |
-
sMax = dt.fnFormatNumber( iMax ),
|
1007 |
-
sTotal = dt.fnFormatNumber( iTotal ),
|
1008 |
-
sOut;
|
1009 |
-
|
1010 |
-
if ( dt.fnRecordsDisplay() === 0 &&
|
1011 |
-
dt.fnRecordsDisplay() == dt.fnRecordsTotal() )
|
1012 |
-
{
|
1013 |
-
/* Empty record set */
|
1014 |
-
sOut = language.sInfoEmpty+ language.sInfoPostFix;
|
1015 |
-
}
|
1016 |
-
else if ( dt.fnRecordsDisplay() === 0 )
|
1017 |
-
{
|
1018 |
-
/* Empty record set after filtering */
|
1019 |
-
sOut = language.sInfoEmpty +' '+
|
1020 |
-
language.sInfoFiltered.replace('_MAX_', sMax)+
|
1021 |
-
language.sInfoPostFix;
|
1022 |
-
}
|
1023 |
-
else if ( dt.fnRecordsDisplay() == dt.fnRecordsTotal() )
|
1024 |
-
{
|
1025 |
-
/* Normal record set */
|
1026 |
-
sOut = language.sInfo.
|
1027 |
-
replace('_START_', sStart).
|
1028 |
-
replace('_END_', sEnd).
|
1029 |
-
replace('_MAX_', sMax).
|
1030 |
-
replace('_TOTAL_', sTotal)+
|
1031 |
-
language.sInfoPostFix;
|
1032 |
-
}
|
1033 |
-
else
|
1034 |
-
{
|
1035 |
-
/* Record set after filtering */
|
1036 |
-
sOut = language.sInfo.
|
1037 |
-
replace('_START_', sStart).
|
1038 |
-
replace('_END_', sEnd).
|
1039 |
-
replace('_MAX_', sMax).
|
1040 |
-
replace('_TOTAL_', sTotal) +' '+
|
1041 |
-
language.sInfoFiltered.replace(
|
1042 |
-
'_MAX_',
|
1043 |
-
dt.fnFormatNumber(dt.fnRecordsTotal())
|
1044 |
-
)+
|
1045 |
-
language.sInfoPostFix;
|
1046 |
-
}
|
1047 |
-
|
1048 |
-
var callback = language.fnInfoCallback;
|
1049 |
-
if ( callback ) {
|
1050 |
-
sOut = callback.call( dt.oInstance,
|
1051 |
-
dt, iStart, iEnd, iMax, iTotal, sOut
|
1052 |
-
);
|
1053 |
-
}
|
1054 |
-
|
1055 |
-
var n = dt.aanFeatures.i;
|
1056 |
-
if ( typeof n != 'undefined' )
|
1057 |
-
{
|
1058 |
-
for ( var i=0, iLen=n.length ; i<iLen ; i++ )
|
1059 |
-
{
|
1060 |
-
$(n[i]).html( sOut );
|
1061 |
-
}
|
1062 |
-
}
|
1063 |
-
|
1064 |
-
// DT doesn't actually (yet) trigger this event, but it will in future
|
1065 |
-
$(dt.nTable).triggerHandler( 'info.dt' );
|
1066 |
-
}
|
1067 |
-
} );
|
1068 |
-
|
1069 |
-
|
1070 |
-
|
1071 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
1072 |
-
* Statics
|
1073 |
-
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
1074 |
-
|
1075 |
-
|
1076 |
-
/**
|
1077 |
-
* Scroller default settings for initialisation
|
1078 |
-
* @namespace
|
1079 |
-
* @name Scroller.defaults
|
1080 |
-
* @static
|
1081 |
-
*/
|
1082 |
-
Scroller.defaults = /** @lends Scroller.defaults */{
|
1083 |
-
/**
|
1084 |
-
* Indicate if Scroller show show trace information on the console or not. This can be
|
1085 |
-
* useful when debugging Scroller or if just curious as to what it is doing, but should
|
1086 |
-
* be turned off for production.
|
1087 |
-
* @type bool
|
1088 |
-
* @default false
|
1089 |
-
* @static
|
1090 |
-
* @example
|
1091 |
-
* var oTable = $('#example').dataTable( {
|
1092 |
-
* "sScrollY": "200px",
|
1093 |
-
* "sDom": "frtiS",
|
1094 |
-
* "bDeferRender": true,
|
1095 |
-
* "oScroller": {
|
1096 |
-
* "trace": true
|
1097 |
-
* }
|
1098 |
-
* } );
|
1099 |
-
*/
|
1100 |
-
"trace": false,
|
1101 |
-
|
1102 |
-
/**
|
1103 |
-
* Scroller will attempt to automatically calculate the height of rows for it's internal
|
1104 |
-
* calculations. However the height that is used can be overridden using this parameter.
|
1105 |
-
* @type int|string
|
1106 |
-
* @default auto
|
1107 |
-
* @static
|
1108 |
-
* @example
|
1109 |
-
* var oTable = $('#example').dataTable( {
|
1110 |
-
* "sScrollY": "200px",
|
1111 |
-
* "sDom": "frtiS",
|
1112 |
-
* "bDeferRender": true,
|
1113 |
-
* "oScroller": {
|
1114 |
-
* "rowHeight": 30
|
1115 |
-
* }
|
1116 |
-
* } );
|
1117 |
-
*/
|
1118 |
-
"rowHeight": "auto",
|
1119 |
-
|
1120 |
-
/**
|
1121 |
-
* When using server-side processing, Scroller will wait a small amount of time to allow
|
1122 |
-
* the scrolling to finish before requesting more data from the server. This prevents
|
1123 |
-
* you from DoSing your own server! The wait time can be configured by this parameter.
|
1124 |
-
* @type int
|
1125 |
-
* @default 200
|
1126 |
-
* @static
|
1127 |
-
* @example
|
1128 |
-
* var oTable = $('#example').dataTable( {
|
1129 |
-
* "sScrollY": "200px",
|
1130 |
-
* "sDom": "frtiS",
|
1131 |
-
* "bDeferRender": true,
|
1132 |
-
* "oScroller": {
|
1133 |
-
* "serverWait": 100
|
1134 |
-
* }
|
1135 |
-
* } );
|
1136 |
-
*/
|
1137 |
-
"serverWait": 200,
|
1138 |
-
|
1139 |
-
/**
|
1140 |
-
* The display buffer is what Scroller uses to calculate how many rows it should pre-fetch
|
1141 |
-
* for scrolling. Scroller automatically adjusts DataTables' display length to pre-fetch
|
1142 |
-
* rows that will be shown in "near scrolling" (i.e. just beyond the current display area).
|
1143 |
-
* The value is based upon the number of rows that can be displayed in the viewport (i.e.
|
1144 |
-
* a value of 1), and will apply the display range to records before before and after the
|
1145 |
-
* current viewport - i.e. a factor of 3 will allow Scroller to pre-fetch 1 viewport's worth
|
1146 |
-
* of rows before the current viewport, the current viewport's rows and 1 viewport's worth
|
1147 |
-
* of rows after the current viewport. Adjusting this value can be useful for ensuring
|
1148 |
-
* smooth scrolling based on your data set.
|
1149 |
-
* @type int
|
1150 |
-
* @default 7
|
1151 |
-
* @static
|
1152 |
-
* @example
|
1153 |
-
* var oTable = $('#example').dataTable( {
|
1154 |
-
* "sScrollY": "200px",
|
1155 |
-
* "sDom": "frtiS",
|
1156 |
-
* "bDeferRender": true,
|
1157 |
-
* "oScroller": {
|
1158 |
-
* "displayBuffer": 10
|
1159 |
-
* }
|
1160 |
-
* } );
|
1161 |
-
*/
|
1162 |
-
"displayBuffer": 9,
|
1163 |
-
|
1164 |
-
/**
|
1165 |
-
* Scroller uses the boundary scaling factor to decide when to redraw the table - which it
|
1166 |
-
* typically does before you reach the end of the currently loaded data set (in order to
|
1167 |
-
* allow the data to look continuous to a user scrolling through the data). If given as 0
|
1168 |
-
* then the table will be redrawn whenever the viewport is scrolled, while 1 would not
|
1169 |
-
* redraw the table until the currently loaded data has all been shown. You will want
|
1170 |
-
* something in the middle - the default factor of 0.5 is usually suitable.
|
1171 |
-
* @type float
|
1172 |
-
* @default 0.5
|
1173 |
-
* @static
|
1174 |
-
* @example
|
1175 |
-
* var oTable = $('#example').dataTable( {
|
1176 |
-
* "sScrollY": "200px",
|
1177 |
-
* "sDom": "frtiS",
|
1178 |
-
* "bDeferRender": true,
|
1179 |
-
* "oScroller": {
|
1180 |
-
* "boundaryScale": 0.75
|
1181 |
-
* }
|
1182 |
-
* } );
|
1183 |
-
*/
|
1184 |
-
"boundaryScale": 0.5,
|
1185 |
-
|
1186 |
-
/**
|
1187 |
-
* Show (or not) the loading element in the background of the table. Note that you should
|
1188 |
-
* include the dataTables.scroller.css file for this to be displayed correctly.
|
1189 |
-
* @type boolean
|
1190 |
-
* @default false
|
1191 |
-
* @static
|
1192 |
-
* @example
|
1193 |
-
* var oTable = $('#example').dataTable( {
|
1194 |
-
* "sScrollY": "200px",
|
1195 |
-
* "sDom": "frtiS",
|
1196 |
-
* "bDeferRender": true,
|
1197 |
-
* "oScroller": {
|
1198 |
-
* "loadingIndicator": true
|
1199 |
-
* }
|
1200 |
-
* } );
|
1201 |
-
*/
|
1202 |
-
"loadingIndicator": false
|
1203 |
-
};
|
1204 |
-
|
1205 |
-
Scroller.oDefaults = Scroller.defaults;
|
1206 |
-
|
1207 |
-
|
1208 |
-
|
1209 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
1210 |
-
* Constants
|
1211 |
-
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
1212 |
-
|
1213 |
-
/**
|
1214 |
-
* Scroller version
|
1215 |
-
* @type String
|
1216 |
-
* @default See code
|
1217 |
-
* @name Scroller.version
|
1218 |
-
* @static
|
1219 |
-
*/
|
1220 |
-
Scroller.version = "1.4.2";
|
1221 |
-
|
1222 |
-
|
1223 |
-
|
1224 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
1225 |
-
* Initialisation
|
1226 |
-
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
1227 |
-
|
1228 |
-
// Legacy `dom` parameter initialisation support
|
1229 |
-
if ( typeof $.fn.dataTable == "function" &&
|
1230 |
-
typeof $.fn.dataTableExt.fnVersionCheck == "function" &&
|
1231 |
-
$.fn.dataTableExt.fnVersionCheck('1.10.0') )
|
1232 |
-
{
|
1233 |
-
$.fn.dataTableExt.aoFeatures.push( {
|
1234 |
-
"fnInit": function( oDTSettings ) {
|
1235 |
-
var init = oDTSettings.oInit;
|
1236 |
-
var opts = init.scroller || init.oScroller || {};
|
1237 |
-
|
1238 |
-
new Scroller( oDTSettings, opts );
|
1239 |
-
},
|
1240 |
-
"cFeature": "S",
|
1241 |
-
"sFeature": "Scroller"
|
1242 |
-
} );
|
1243 |
-
}
|
1244 |
-
else
|
1245 |
-
{
|
1246 |
-
alert( "Warning: Scroller requires DataTables 1.10.0 or greater - www.datatables.net/download");
|
1247 |
-
}
|
1248 |
-
|
1249 |
-
// Attach a listener to the document which listens for DataTables initialisation
|
1250 |
-
// events so we can automatically initialise
|
1251 |
-
$(document).on( 'preInit.dt.dtscroller', function (e, settings) {
|
1252 |
-
if ( e.namespace !== 'dt' ) {
|
1253 |
-
return;
|
1254 |
-
}
|
1255 |
-
|
1256 |
-
var init = settings.oInit.scroller;
|
1257 |
-
var defaults = DataTable.defaults.scroller;
|
1258 |
-
|
1259 |
-
if ( init || defaults ) {
|
1260 |
-
var opts = $.extend( {}, init, defaults );
|
1261 |
-
|
1262 |
-
if ( init !== false ) {
|
1263 |
-
new Scroller( settings, opts );
|
1264 |
-
}
|
1265 |
-
}
|
1266 |
-
} );
|
1267 |
-
|
1268 |
-
|
1269 |
-
// Attach Scroller to DataTables so it can be accessed as an 'extra'
|
1270 |
-
$.fn.dataTable.Scroller = Scroller;
|
1271 |
-
$.fn.DataTable.Scroller = Scroller;
|
1272 |
-
|
1273 |
-
|
1274 |
-
// DataTables 1.10 API method aliases
|
1275 |
-
var Api = $.fn.dataTable.Api;
|
1276 |
-
|
1277 |
-
Api.register( 'scroller()', function () {
|
1278 |
-
return this;
|
1279 |
-
} );
|
1280 |
-
|
1281 |
-
// Undocumented and deprecated - is it actually useful at all?
|
1282 |
-
Api.register( 'scroller().rowToPixels()', function ( rowIdx, intParse, virtual ) {
|
1283 |
-
var ctx = this.context;
|
1284 |
-
|
1285 |
-
if ( ctx.length && ctx[0].oScroller ) {
|
1286 |
-
return ctx[0].oScroller.fnRowToPixels( rowIdx, intParse, virtual );
|
1287 |
-
}
|
1288 |
-
// undefined
|
1289 |
-
} );
|
1290 |
-
|
1291 |
-
// Undocumented and deprecated - is it actually useful at all?
|
1292 |
-
Api.register( 'scroller().pixelsToRow()', function ( pixels, intParse, virtual ) {
|
1293 |
-
var ctx = this.context;
|
1294 |
-
|
1295 |
-
if ( ctx.length && ctx[0].oScroller ) {
|
1296 |
-
return ctx[0].oScroller.fnPixelsToRow( pixels, intParse, virtual );
|
1297 |
-
}
|
1298 |
-
// undefined
|
1299 |
-
} );
|
1300 |
-
|
1301 |
-
// Undocumented and deprecated - use `row().scrollTo()` instead
|
1302 |
-
Api.register( 'scroller().scrollToRow()', function ( row, ani ) {
|
1303 |
-
this.iterator( 'table', function ( ctx ) {
|
1304 |
-
if ( ctx.oScroller ) {
|
1305 |
-
ctx.oScroller.fnScrollToRow( row, ani );
|
1306 |
-
}
|
1307 |
-
} );
|
1308 |
-
|
1309 |
-
return this;
|
1310 |
-
} );
|
1311 |
-
|
1312 |
-
Api.register( 'row().scrollTo()', function ( ani ) {
|
1313 |
-
var that = this;
|
1314 |
-
|
1315 |
-
this.iterator( 'row', function ( ctx, rowIdx ) {
|
1316 |
-
if ( ctx.oScroller ) {
|
1317 |
-
var displayIdx = that
|
1318 |
-
.rows( { order: 'applied', search: 'applied' } )
|
1319 |
-
.indexes()
|
1320 |
-
.indexOf( rowIdx );
|
1321 |
-
|
1322 |
-
ctx.oScroller.fnScrollToRow( displayIdx, ani );
|
1323 |
-
}
|
1324 |
-
} );
|
1325 |
-
|
1326 |
-
return this;
|
1327 |
-
} );
|
1328 |
-
|
1329 |
-
Api.register( 'scroller.measure()', function ( redraw ) {
|
1330 |
-
this.iterator( 'table', function ( ctx ) {
|
1331 |
-
if ( ctx.oScroller ) {
|
1332 |
-
ctx.oScroller.fnMeasure( redraw );
|
1333 |
-
}
|
1334 |
-
} );
|
1335 |
-
|
1336 |
-
return this;
|
1337 |
-
} );
|
1338 |
-
|
1339 |
-
Api.register( 'scroller.page()', function() {
|
1340 |
-
var ctx = this.context;
|
1341 |
-
|
1342 |
-
if ( ctx.length && ctx[0].oScroller ) {
|
1343 |
-
return ctx[0].oScroller.fnPageInfo();
|
1344 |
-
}
|
1345 |
-
// undefined
|
1346 |
-
} );
|
1347 |
-
|
1348 |
-
return Scroller;
|
1349 |
-
}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Scroller/js/dataTables.scroller.min.js
DELETED
@@ -1,27 +0,0 @@
|
|
1 |
-
/*!
|
2 |
-
Scroller 1.4.2
|
3 |
-
©2011-2016 SpryMedia Ltd - datatables.net/license
|
4 |
-
*/
|
5 |
-
(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(h){return e(h,window,document)}):"object"===typeof exports?module.exports=function(h,j){h||(h=window);if(!j||!j.fn.dataTable)j=require("datatables.net")(h,j).$;return e(j,h,h.document)}:e(jQuery,window,document)})(function(e,h,j,l){var m=e.fn.dataTable,g=function(a,b){this instanceof g?(b===l&&(b={}),this.s={dt:e.fn.dataTable.Api(a).settings()[0],tableTop:0,tableBottom:0,redrawTop:0,redrawBottom:0,autoHeight:!0,
|
6 |
-
viewportRows:0,stateTO:null,drawTO:null,heights:{jump:null,page:null,virtual:null,scroll:null,row:null,viewport:null},topRowFloat:0,scrollDrawDiff:null,loaderVisible:!1},this.s=e.extend(this.s,g.oDefaults,b),this.s.heights.row=this.s.rowHeight,this.dom={force:j.createElement("div"),scroller:null,table:null,loader:null},this.s.dt.oScroller||(this.s.dt.oScroller=this,this._fnConstruct())):alert("Scroller warning: Scroller must be initialised with the 'new' keyword.")};e.extend(g.prototype,{fnRowToPixels:function(a,
|
7 |
-
b,c){a=c?this._domain("virtualToPhysical",a*this.s.heights.row):this.s.baseScrollTop+(a-this.s.baseRowTop)*this.s.heights.row;return b||b===l?parseInt(a,10):a},fnPixelsToRow:function(a,b,c){var d=a-this.s.baseScrollTop,a=c?this._domain("physicalToVirtual",a)/this.s.heights.row:d/this.s.heights.row+this.s.baseRowTop;return b||b===l?parseInt(a,10):a},fnScrollToRow:function(a,b){var c=this,d=!1,f=this.fnRowToPixels(a),i=a-(this.s.displayBuffer-1)/2*this.s.viewportRows;0>i&&(i=0);if((f>this.s.redrawBottom||
|
8 |
-
f<this.s.redrawTop)&&this.s.dt._iDisplayStart!==i)d=!0,f=this.fnRowToPixels(a,!1,!0);"undefined"==typeof b||b?(this.s.ani=d,e(this.dom.scroller).animate({scrollTop:f},function(){setTimeout(function(){c.s.ani=!1},25)})):e(this.dom.scroller).scrollTop(f)},fnMeasure:function(a){this.s.autoHeight&&this._fnCalcRowHeight();var b=this.s.heights;b.row&&(b.viewport=e(this.dom.scroller).height(),this.s.viewportRows=parseInt(b.viewport/b.row,10)+1,this.s.dt._iDisplayLength=this.s.viewportRows*this.s.displayBuffer);
|
9 |
-
(a===l||a)&&this.s.dt.oInstance.fnDraw(!1)},fnPageInfo:function(){var a=this.dom.scroller.scrollTop,b=this.s.dt.fnRecordsDisplay(),c=Math.ceil(this.fnPixelsToRow(a+this.s.heights.viewport,!1,this.s.ani));return{start:Math.floor(this.fnPixelsToRow(a,!1,this.s.ani)),end:b<c?b-1:c-1}},_fnConstruct:function(){var a=this;if(this.s.dt.oFeatures.bPaginate){this.dom.force.style.position="relative";this.dom.force.style.top="0px";this.dom.force.style.left="0px";this.dom.force.style.width="1px";this.dom.scroller=
|
10 |
-
e("div."+this.s.dt.oClasses.sScrollBody,this.s.dt.nTableWrapper)[0];this.dom.scroller.appendChild(this.dom.force);this.dom.scroller.style.position="relative";this.dom.table=e(">table",this.dom.scroller)[0];this.dom.table.style.position="absolute";this.dom.table.style.top="0px";this.dom.table.style.left="0px";e(this.s.dt.nTableWrapper).addClass("DTS");this.s.loadingIndicator&&(this.dom.loader=e('<div class="dataTables_processing DTS_Loading">'+this.s.dt.oLanguage.sLoadingRecords+"</div>").css("display",
|
11 |
-
"none"),e(this.dom.scroller.parentNode).css("position","relative").append(this.dom.loader));this.s.heights.row&&"auto"!=this.s.heights.row&&(this.s.autoHeight=!1);this.fnMeasure(!1);this.s.ingnoreScroll=!0;this.s.stateSaveThrottle=this.s.dt.oApi._fnThrottle(function(){a.s.dt.oApi._fnSaveState(a.s.dt)},500);e(this.dom.scroller).on("scroll.DTS",function(){a._fnScroll.call(a)});e(this.dom.scroller).on("touchstart.DTS",function(){a._fnScroll.call(a)});this.s.dt.aoDrawCallback.push({fn:function(){a.s.dt.bInitialised&&
|
12 |
-
a._fnDrawCallback.call(a)},sName:"Scroller"});e(h).on("resize.DTS",function(){a.fnMeasure(false);a._fnInfo()});var b=!0;this.s.dt.oApi._fnCallbackReg(this.s.dt,"aoStateSaveParams",function(c,d){if(b&&a.s.dt.oLoadedState){d.iScroller=a.s.dt.oLoadedState.iScroller;d.iScrollerTopRow=a.s.dt.oLoadedState.iScrollerTopRow;b=false}else{d.iScroller=a.dom.scroller.scrollTop;d.iScrollerTopRow=a.s.topRowFloat}},"Scroller_State");this.s.dt.oLoadedState&&(this.s.topRowFloat=this.s.dt.oLoadedState.iScrollerTopRow||
|
13 |
-
0);e(this.s.dt.nTable).one("init.dt",function(){a.fnMeasure()});this.s.dt.aoDestroyCallback.push({sName:"Scroller",fn:function(){e(h).off("resize.DTS");e(a.dom.scroller).off("touchstart.DTS scroll.DTS");e(a.s.dt.nTableWrapper).removeClass("DTS");e("div.DTS_Loading",a.dom.scroller.parentNode).remove();e(a.s.dt.nTable).off("init.dt");a.dom.table.style.position="";a.dom.table.style.top="";a.dom.table.style.left=""}})}else this.s.dt.oApi._fnLog(this.s.dt,0,"Pagination must be enabled for Scroller")},
|
14 |
-
_fnScroll:function(){var a=this,b=this.s.heights,c=this.dom.scroller.scrollTop,d;if(!this.s.skip&&!this.s.ingnoreScroll)if(this.s.dt.bFiltered||this.s.dt.bSorted)this.s.lastScrollTop=0;else{this._fnInfo();clearTimeout(this.s.stateTO);this.s.stateTO=setTimeout(function(){a.s.dt.oApi._fnSaveState(a.s.dt)},250);if(c<this.s.redrawTop||c>this.s.redrawBottom){var f=Math.ceil((this.s.displayBuffer-1)/2*this.s.viewportRows);Math.abs(c-this.s.lastScrollTop)>b.viewport||this.s.ani?(d=parseInt(this._domain("physicalToVirtual",
|
15 |
-
c)/b.row,10)-f,this.s.topRowFloat=this._domain("physicalToVirtual",c)/b.row):(d=this.fnPixelsToRow(c)-f,this.s.topRowFloat=this.fnPixelsToRow(c,!1));0>=d?d=0:d+this.s.dt._iDisplayLength>this.s.dt.fnRecordsDisplay()?(d=this.s.dt.fnRecordsDisplay()-this.s.dt._iDisplayLength,0>d&&(d=0)):0!==d%2&&d++;if(d!=this.s.dt._iDisplayStart&&(this.s.tableTop=e(this.s.dt.nTable).offset().top,this.s.tableBottom=e(this.s.dt.nTable).height()+this.s.tableTop,b=function(){if(a.s.scrollDrawReq===null)a.s.scrollDrawReq=
|
16 |
-
c;a.s.dt._iDisplayStart=d;a.s.dt.oApi._fnDraw(a.s.dt)},this.s.dt.oFeatures.bServerSide?(clearTimeout(this.s.drawTO),this.s.drawTO=setTimeout(b,this.s.serverWait)):b(),this.dom.loader&&!this.s.loaderVisible))this.dom.loader.css("display","block"),this.s.loaderVisible=!0}else this.s.topRowFloat=this._domain("physicalToVirtual",c)/b.row;this.s.lastScrollTop=c;this.s.stateSaveThrottle()}},_domain:function(a,b){var c=this.s.heights,d;if(c.virtual===c.scroll)return b;var e=(c.scroll-c.viewport)/2,i=(c.virtual-
|
17 |
-
c.viewport)/2;d=i/(e*e);if("virtualToPhysical"===a){if(b<i)return Math.pow(b/d,0.5);b=2*i-b;return 0>b?c.scroll:2*e-Math.pow(b/d,0.5)}if("physicalToVirtual"===a){if(b<e)return b*b*d;b=2*e-b;return 0>b?c.virtual:2*i-b*b*d}},_fnDrawCallback:function(){var a=this,b=this.s.heights,c=this.dom.scroller.scrollTop,d=e(this.s.dt.nTable).height(),f=this.s.dt._iDisplayStart,i=this.s.dt._iDisplayLength,g=this.s.dt.fnRecordsDisplay();this.s.skip=!0;this._fnScrollForce();c=0===f?this.s.topRowFloat*b.row:f+i>=g?
|
18 |
-
b.scroll-(g-this.s.topRowFloat)*b.row:this._domain("virtualToPhysical",this.s.topRowFloat*b.row);this.dom.scroller.scrollTop=c;this.s.baseScrollTop=c;this.s.baseRowTop=this.s.topRowFloat;var h=c-(this.s.topRowFloat-f)*b.row;0===f?h=0:f+i>=g&&(h=b.scroll-d);this.dom.table.style.top=h+"px";this.s.tableTop=h;this.s.tableBottom=d+this.s.tableTop;d=(c-this.s.tableTop)*this.s.boundaryScale;this.s.redrawTop=c-d;this.s.redrawBottom=c+d;this.s.skip=!1;this.s.dt.oFeatures.bStateSave&&null!==this.s.dt.oLoadedState&&
|
19 |
-
"undefined"!=typeof this.s.dt.oLoadedState.iScroller?((c=(this.s.dt.sAjaxSource||a.s.dt.ajax)&&!this.s.dt.oFeatures.bServerSide?!0:!1)&&2==this.s.dt.iDraw||!c&&1==this.s.dt.iDraw)&&setTimeout(function(){e(a.dom.scroller).scrollTop(a.s.dt.oLoadedState.iScroller);a.s.redrawTop=a.s.dt.oLoadedState.iScroller-b.viewport/2;setTimeout(function(){a.s.ingnoreScroll=!1},0)},0):a.s.ingnoreScroll=!1;this.s.dt.oFeatures.bInfo&&setTimeout(function(){a._fnInfo.call(a)},0);this.dom.loader&&this.s.loaderVisible&&
|
20 |
-
(this.dom.loader.css("display","none"),this.s.loaderVisible=!1)},_fnScrollForce:function(){var a=this.s.heights;a.virtual=a.row*this.s.dt.fnRecordsDisplay();a.scroll=a.virtual;1E6<a.scroll&&(a.scroll=1E6);this.dom.force.style.height=a.scroll>this.s.heights.row?a.scroll+"px":this.s.heights.row+"px"},_fnCalcRowHeight:function(){var a=this.s.dt,b=a.nTable,c=b.cloneNode(!1),d=e("<tbody/>").appendTo(c),f=e('<div class="'+a.oClasses.sWrapper+' DTS"><div class="'+a.oClasses.sScrollWrapper+'"><div class="'+
|
21 |
-
a.oClasses.sScrollBody+'"></div></div></div>');for(e("tbody tr:lt(4)",b).clone().appendTo(d);3>e("tr",d).length;)d.append("<tr><td> </td></tr>");e("div."+a.oClasses.sScrollBody,f).append(c);a=this.s.dt.nHolding||b.parentNode;e(a).is(":visible")||(a="body");f.appendTo(a);this.s.heights.row=e("tr",d).eq(1).outerHeight();f.remove()},_fnInfo:function(){if(this.s.dt.oFeatures.bInfo){var a=this.s.dt,b=a.oLanguage,c=this.dom.scroller.scrollTop,d=Math.floor(this.fnPixelsToRow(c,!1,this.s.ani)+1),f=a.fnRecordsTotal(),
|
22 |
-
i=a.fnRecordsDisplay(),c=Math.ceil(this.fnPixelsToRow(c+this.s.heights.viewport,!1,this.s.ani)),c=i<c?i:c,g=a.fnFormatNumber(d),h=a.fnFormatNumber(c),j=a.fnFormatNumber(f),k=a.fnFormatNumber(i),g=0===a.fnRecordsDisplay()&&a.fnRecordsDisplay()==a.fnRecordsTotal()?b.sInfoEmpty+b.sInfoPostFix:0===a.fnRecordsDisplay()?b.sInfoEmpty+" "+b.sInfoFiltered.replace("_MAX_",j)+b.sInfoPostFix:a.fnRecordsDisplay()==a.fnRecordsTotal()?b.sInfo.replace("_START_",g).replace("_END_",h).replace("_MAX_",j).replace("_TOTAL_",
|
23 |
-
k)+b.sInfoPostFix:b.sInfo.replace("_START_",g).replace("_END_",h).replace("_MAX_",j).replace("_TOTAL_",k)+" "+b.sInfoFiltered.replace("_MAX_",a.fnFormatNumber(a.fnRecordsTotal()))+b.sInfoPostFix;(b=b.fnInfoCallback)&&(g=b.call(a.oInstance,a,d,c,f,i,g));d=a.aanFeatures.i;if("undefined"!=typeof d){f=0;for(i=d.length;f<i;f++)e(d[f]).html(g)}e(a.nTable).triggerHandler("info.dt")}}});g.defaults={trace:!1,rowHeight:"auto",serverWait:200,displayBuffer:9,boundaryScale:0.5,loadingIndicator:!1};g.oDefaults=
|
24 |
-
g.defaults;g.version="1.4.2";"function"==typeof e.fn.dataTable&&"function"==typeof e.fn.dataTableExt.fnVersionCheck&&e.fn.dataTableExt.fnVersionCheck("1.10.0")?e.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var b=a.oInit;new g(a,b.scroller||b.oScroller||{})},cFeature:"S",sFeature:"Scroller"}):alert("Warning: Scroller requires DataTables 1.10.0 or greater - www.datatables.net/download");e(j).on("preInit.dt.dtscroller",function(a,b){if("dt"===a.namespace){var c=b.oInit.scroller,d=m.defaults.scroller;
|
25 |
-
if(c||d)d=e.extend({},c,d),!1!==c&&new g(b,d)}});e.fn.dataTable.Scroller=g;e.fn.DataTable.Scroller=g;var k=e.fn.dataTable.Api;k.register("scroller()",function(){return this});k.register("scroller().rowToPixels()",function(a,b,c){var d=this.context;if(d.length&&d[0].oScroller)return d[0].oScroller.fnRowToPixels(a,b,c)});k.register("scroller().pixelsToRow()",function(a,b,c){var d=this.context;if(d.length&&d[0].oScroller)return d[0].oScroller.fnPixelsToRow(a,b,c)});k.register("scroller().scrollToRow()",
|
26 |
-
function(a,b){this.iterator("table",function(c){c.oScroller&&c.oScroller.fnScrollToRow(a,b)});return this});k.register("row().scrollTo()",function(a){var b=this;this.iterator("row",function(c,d){if(c.oScroller){var e=b.rows({order:"applied",search:"applied"}).indexes().indexOf(d);c.oScroller.fnScrollToRow(e,a)}});return this});k.register("scroller.measure()",function(a){this.iterator("table",function(b){b.oScroller&&b.oScroller.fnMeasure(a)});return this});k.register("scroller.page()",function(){var a=
|
27 |
-
this.context;if(a.length&&a[0].oScroller)return a[0].oScroller.fnPageInfo()});return g});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Select/css/select.dataTables.css
DELETED
@@ -1,100 +0,0 @@
|
|
1 |
-
table.dataTable tbody > tr.selected,
|
2 |
-
table.dataTable tbody > tr > .selected {
|
3 |
-
background-color: #B0BED9;
|
4 |
-
}
|
5 |
-
table.dataTable.stripe tbody > tr.odd.selected,
|
6 |
-
table.dataTable.stripe tbody > tr.odd > .selected, table.dataTable.display tbody > tr.odd.selected,
|
7 |
-
table.dataTable.display tbody > tr.odd > .selected {
|
8 |
-
background-color: #acbad4;
|
9 |
-
}
|
10 |
-
table.dataTable.hover tbody > tr.selected:hover,
|
11 |
-
table.dataTable.hover tbody > tr > .selected:hover, table.dataTable.display tbody > tr.selected:hover,
|
12 |
-
table.dataTable.display tbody > tr > .selected:hover {
|
13 |
-
background-color: #aab7d1;
|
14 |
-
}
|
15 |
-
table.dataTable.order-column tbody > tr.selected > .sorting_1,
|
16 |
-
table.dataTable.order-column tbody > tr.selected > .sorting_2,
|
17 |
-
table.dataTable.order-column tbody > tr.selected > .sorting_3,
|
18 |
-
table.dataTable.order-column tbody > tr > .selected, table.dataTable.display tbody > tr.selected > .sorting_1,
|
19 |
-
table.dataTable.display tbody > tr.selected > .sorting_2,
|
20 |
-
table.dataTable.display tbody > tr.selected > .sorting_3,
|
21 |
-
table.dataTable.display tbody > tr > .selected {
|
22 |
-
background-color: #acbad5;
|
23 |
-
}
|
24 |
-
table.dataTable.display tbody > tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_1 {
|
25 |
-
background-color: #a6b4cd;
|
26 |
-
}
|
27 |
-
table.dataTable.display tbody > tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_2 {
|
28 |
-
background-color: #a8b5cf;
|
29 |
-
}
|
30 |
-
table.dataTable.display tbody > tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody > tr.odd.selected > .sorting_3 {
|
31 |
-
background-color: #a9b7d1;
|
32 |
-
}
|
33 |
-
table.dataTable.display tbody > tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_1 {
|
34 |
-
background-color: #acbad5;
|
35 |
-
}
|
36 |
-
table.dataTable.display tbody > tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_2 {
|
37 |
-
background-color: #aebcd6;
|
38 |
-
}
|
39 |
-
table.dataTable.display tbody > tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody > tr.even.selected > .sorting_3 {
|
40 |
-
background-color: #afbdd8;
|
41 |
-
}
|
42 |
-
table.dataTable.display tbody > tr.odd > .selected, table.dataTable.order-column.stripe tbody > tr.odd > .selected {
|
43 |
-
background-color: #a6b4cd;
|
44 |
-
}
|
45 |
-
table.dataTable.display tbody > tr.even > .selected, table.dataTable.order-column.stripe tbody > tr.even > .selected {
|
46 |
-
background-color: #acbad5;
|
47 |
-
}
|
48 |
-
table.dataTable.display tbody > tr.selected:hover > .sorting_1, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_1 {
|
49 |
-
background-color: #a2aec7;
|
50 |
-
}
|
51 |
-
table.dataTable.display tbody > tr.selected:hover > .sorting_2, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_2 {
|
52 |
-
background-color: #a3b0c9;
|
53 |
-
}
|
54 |
-
table.dataTable.display tbody > tr.selected:hover > .sorting_3, table.dataTable.order-column.hover tbody > tr.selected:hover > .sorting_3 {
|
55 |
-
background-color: #a5b2cb;
|
56 |
-
}
|
57 |
-
table.dataTable.display tbody > tr:hover > .selected,
|
58 |
-
table.dataTable.display tbody > tr > .selected:hover, table.dataTable.order-column.hover tbody > tr:hover > .selected,
|
59 |
-
table.dataTable.order-column.hover tbody > tr > .selected:hover {
|
60 |
-
background-color: #a2aec7;
|
61 |
-
}
|
62 |
-
table.dataTable td.select-checkbox {
|
63 |
-
position: relative;
|
64 |
-
}
|
65 |
-
table.dataTable td.select-checkbox:before, table.dataTable td.select-checkbox:after {
|
66 |
-
display: block;
|
67 |
-
position: absolute;
|
68 |
-
top: 1.2em;
|
69 |
-
left: 50%;
|
70 |
-
width: 12px;
|
71 |
-
height: 12px;
|
72 |
-
box-sizing: border-box;
|
73 |
-
}
|
74 |
-
table.dataTable td.select-checkbox:before {
|
75 |
-
content: ' ';
|
76 |
-
margin-top: -6px;
|
77 |
-
margin-left: -6px;
|
78 |
-
border: 1px solid black;
|
79 |
-
border-radius: 3px;
|
80 |
-
}
|
81 |
-
table.dataTable tr.selected td.select-checkbox:after {
|
82 |
-
content: '\2714';
|
83 |
-
margin-top: -11px;
|
84 |
-
margin-left: -4px;
|
85 |
-
text-align: center;
|
86 |
-
text-shadow: 1px 1px #B0BED9, -1px -1px #B0BED9, 1px -1px #B0BED9, -1px 1px #B0BED9;
|
87 |
-
}
|
88 |
-
|
89 |
-
div.dataTables_wrapper span.select-info,
|
90 |
-
div.dataTables_wrapper span.select-item {
|
91 |
-
margin-left: 0.5em;
|
92 |
-
}
|
93 |
-
|
94 |
-
@media screen and (max-width: 640px) {
|
95 |
-
div.dataTables_wrapper span.select-info,
|
96 |
-
div.dataTables_wrapper span.select-item {
|
97 |
-
margin-left: 0;
|
98 |
-
display: block;
|
99 |
-
}
|
100 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Select/css/select.dataTables.min.css
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
table.dataTable tbody>tr.selected,table.dataTable tbody>tr>.selected{background-color:#B0BED9}table.dataTable.stripe tbody>tr.odd.selected,table.dataTable.stripe tbody>tr.odd>.selected,table.dataTable.display tbody>tr.odd.selected,table.dataTable.display tbody>tr.odd>.selected{background-color:#acbad4}table.dataTable.hover tbody>tr.selected:hover,table.dataTable.hover tbody>tr>.selected:hover,table.dataTable.display tbody>tr.selected:hover,table.dataTable.display tbody>tr>.selected:hover{background-color:#aab7d1}table.dataTable.order-column tbody>tr.selected>.sorting_1,table.dataTable.order-column tbody>tr.selected>.sorting_2,table.dataTable.order-column tbody>tr.selected>.sorting_3,table.dataTable.order-column tbody>tr>.selected,table.dataTable.display tbody>tr.selected>.sorting_1,table.dataTable.display tbody>tr.selected>.sorting_2,table.dataTable.display tbody>tr.selected>.sorting_3,table.dataTable.display tbody>tr>.selected{background-color:#acbad5}table.dataTable.display tbody>tr.odd.selected>.sorting_1,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_1{background-color:#a6b4cd}table.dataTable.display tbody>tr.odd.selected>.sorting_2,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_2{background-color:#a8b5cf}table.dataTable.display tbody>tr.odd.selected>.sorting_3,table.dataTable.order-column.stripe tbody>tr.odd.selected>.sorting_3{background-color:#a9b7d1}table.dataTable.display tbody>tr.even.selected>.sorting_1,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_1{background-color:#acbad5}table.dataTable.display tbody>tr.even.selected>.sorting_2,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_2{background-color:#aebcd6}table.dataTable.display tbody>tr.even.selected>.sorting_3,table.dataTable.order-column.stripe tbody>tr.even.selected>.sorting_3{background-color:#afbdd8}table.dataTable.display tbody>tr.odd>.selected,table.dataTable.order-column.stripe tbody>tr.odd>.selected{background-color:#a6b4cd}table.dataTable.display tbody>tr.even>.selected,table.dataTable.order-column.stripe tbody>tr.even>.selected{background-color:#acbad5}table.dataTable.display tbody>tr.selected:hover>.sorting_1,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_1{background-color:#a2aec7}table.dataTable.display tbody>tr.selected:hover>.sorting_2,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_2{background-color:#a3b0c9}table.dataTable.display tbody>tr.selected:hover>.sorting_3,table.dataTable.order-column.hover tbody>tr.selected:hover>.sorting_3{background-color:#a5b2cb}table.dataTable.display tbody>tr:hover>.selected,table.dataTable.display tbody>tr>.selected:hover,table.dataTable.order-column.hover tbody>tr:hover>.selected,table.dataTable.order-column.hover tbody>tr>.selected:hover{background-color:#a2aec7}table.dataTable td.select-checkbox{position:relative}table.dataTable td.select-checkbox:before,table.dataTable td.select-checkbox:after{display:block;position:absolute;top:1.2em;left:50%;width:12px;height:12px;box-sizing:border-box}table.dataTable td.select-checkbox:before{content:' ';margin-top:-6px;margin-left:-6px;border:1px solid black;border-radius:3px}table.dataTable tr.selected td.select-checkbox:after{content:'\2714';margin-top:-11px;margin-left:-4px;text-align:center;text-shadow:1px 1px #B0BED9, -1px -1px #B0BED9, 1px -1px #B0BED9, -1px 1px #B0BED9}div.dataTables_wrapper span.select-info,div.dataTables_wrapper span.select-item{margin-left:0.5em}@media screen and (max-width: 640px){div.dataTables_wrapper span.select-info,div.dataTables_wrapper span.select-item{margin-left:0;display:block}}
|
|
common/vendor/datatables/extensions/Select/js/dataTables.select.js
DELETED
@@ -1,1109 +0,0 @@
|
|
1 |
-
/*! Select for DataTables 1.2.0
|
2 |
-
* 2015-2016 SpryMedia Ltd - datatables.net/license/mit
|
3 |
-
*/
|
4 |
-
|
5 |
-
/**
|
6 |
-
* @summary Select for DataTables
|
7 |
-
* @description A collection of API methods, events and buttons for DataTables
|
8 |
-
* that provides selection options of the items in a DataTable
|
9 |
-
* @version 1.2.0
|
10 |
-
* @file dataTables.select.js
|
11 |
-
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
12 |
-
* @contact datatables.net/forums
|
13 |
-
* @copyright Copyright 2015-2016 SpryMedia Ltd.
|
14 |
-
*
|
15 |
-
* This source file is free software, available under the following license:
|
16 |
-
* MIT license - http://datatables.net/license/mit
|
17 |
-
*
|
18 |
-
* This source file is distributed in the hope that it will be useful, but
|
19 |
-
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
20 |
-
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
21 |
-
*
|
22 |
-
* For details please refer to: http://www.datatables.net/extensions/select
|
23 |
-
*/
|
24 |
-
(function( factory ){
|
25 |
-
if ( typeof define === 'function' && define.amd ) {
|
26 |
-
// AMD
|
27 |
-
define( ['jquery', 'datatables.net'], function ( $ ) {
|
28 |
-
return factory( $, window, document );
|
29 |
-
} );
|
30 |
-
}
|
31 |
-
else if ( typeof exports === 'object' ) {
|
32 |
-
// CommonJS
|
33 |
-
module.exports = function (root, $) {
|
34 |
-
if ( ! root ) {
|
35 |
-
root = window;
|
36 |
-
}
|
37 |
-
|
38 |
-
if ( ! $ || ! $.fn.dataTable ) {
|
39 |
-
$ = require('datatables.net')(root, $).$;
|
40 |
-
}
|
41 |
-
|
42 |
-
return factory( $, root, root.document );
|
43 |
-
};
|
44 |
-
}
|
45 |
-
else {
|
46 |
-
// Browser
|
47 |
-
factory( jQuery, window, document );
|
48 |
-
}
|
49 |
-
}(function( $, window, document, undefined ) {
|
50 |
-
'use strict';
|
51 |
-
var DataTable = $.fn.dataTable;
|
52 |
-
|
53 |
-
|
54 |
-
// Version information for debugger
|
55 |
-
DataTable.select = {};
|
56 |
-
|
57 |
-
DataTable.select.version = '1.2.0';
|
58 |
-
|
59 |
-
DataTable.select.init = function ( dt ) {
|
60 |
-
var ctx = dt.settings()[0];
|
61 |
-
var init = ctx.oInit.select;
|
62 |
-
var defaults = DataTable.defaults.select;
|
63 |
-
var opts = init === undefined ?
|
64 |
-
defaults :
|
65 |
-
init;
|
66 |
-
|
67 |
-
// Set defaults
|
68 |
-
var items = 'row';
|
69 |
-
var style = 'api';
|
70 |
-
var blurable = false;
|
71 |
-
var info = true;
|
72 |
-
var selector = 'td, th';
|
73 |
-
var className = 'selected';
|
74 |
-
|
75 |
-
ctx._select = {};
|
76 |
-
|
77 |
-
// Initialisation customisations
|
78 |
-
if ( opts === true ) {
|
79 |
-
style = 'os';
|
80 |
-
}
|
81 |
-
else if ( typeof opts === 'string' ) {
|
82 |
-
style = opts;
|
83 |
-
}
|
84 |
-
else if ( $.isPlainObject( opts ) ) {
|
85 |
-
if ( opts.blurable !== undefined ) {
|
86 |
-
blurable = opts.blurable;
|
87 |
-
}
|
88 |
-
|
89 |
-
if ( opts.info !== undefined ) {
|
90 |
-
info = opts.info;
|
91 |
-
}
|
92 |
-
|
93 |
-
if ( opts.items !== undefined ) {
|
94 |
-
items = opts.items;
|
95 |
-
}
|
96 |
-
|
97 |
-
if ( opts.style !== undefined ) {
|
98 |
-
style = opts.style;
|
99 |
-
}
|
100 |
-
|
101 |
-
if ( opts.selector !== undefined ) {
|
102 |
-
selector = opts.selector;
|
103 |
-
}
|
104 |
-
|
105 |
-
if ( opts.className !== undefined ) {
|
106 |
-
className = opts.className;
|
107 |
-
}
|
108 |
-
}
|
109 |
-
|
110 |
-
dt.select.selector( selector );
|
111 |
-
dt.select.items( items );
|
112 |
-
dt.select.style( style );
|
113 |
-
dt.select.blurable( blurable );
|
114 |
-
dt.select.info( info );
|
115 |
-
ctx._select.className = className;
|
116 |
-
|
117 |
-
|
118 |
-
// Sort table based on selected rows. Requires Select Datatables extension
|
119 |
-
$.fn.dataTable.ext.order['select-checkbox'] = function ( settings, col ) {
|
120 |
-
return this.api().column( col, {order: 'index'} ).nodes().map( function ( td ) {
|
121 |
-
if ( settings._select.items === 'row' ) {
|
122 |
-
return $( td ).parent().hasClass( settings._select.className );
|
123 |
-
} else if ( settings._select.items === 'cell' ) {
|
124 |
-
return $( td ).hasClass( settings._select.className );
|
125 |
-
}
|
126 |
-
return false;
|
127 |
-
});
|
128 |
-
};
|
129 |
-
|
130 |
-
// If the init options haven't enabled select, but there is a selectable
|
131 |
-
// class name, then enable
|
132 |
-
if ( $( dt.table().node() ).hasClass( 'selectable' ) ) {
|
133 |
-
dt.select.style( 'os' );
|
134 |
-
}
|
135 |
-
};
|
136 |
-
|
137 |
-
/*
|
138 |
-
|
139 |
-
Select is a collection of API methods, event handlers, event emitters and
|
140 |
-
buttons (for the `Buttons` extension) for DataTables. It provides the following
|
141 |
-
features, with an overview of how they are implemented:
|
142 |
-
|
143 |
-
## Selection of rows, columns and cells. Whether an item is selected or not is
|
144 |
-
stored in:
|
145 |
-
|
146 |
-
* rows: a `_select_selected` property which contains a boolean value of the
|
147 |
-
DataTables' `aoData` object for each row
|
148 |
-
* columns: a `_select_selected` property which contains a boolean value of the
|
149 |
-
DataTables' `aoColumns` object for each column
|
150 |
-
* cells: a `_selected_cells` property which contains an array of boolean values
|
151 |
-
of the `aoData` object for each row. The array is the same length as the
|
152 |
-
columns array, with each element of it representing a cell.
|
153 |
-
|
154 |
-
This method of using boolean flags allows Select to operate when nodes have not
|
155 |
-
been created for rows / cells (DataTables' defer rendering feature).
|
156 |
-
|
157 |
-
## API methods
|
158 |
-
|
159 |
-
A range of API methods are available for triggering selection and de-selection
|
160 |
-
of rows. Methods are also available to configure the selection events that can
|
161 |
-
be triggered by an end user (such as which items are to be selected). To a large
|
162 |
-
extent, these of API methods *is* Select. It is basically a collection of helper
|
163 |
-
functions that can be used to select items in a DataTable.
|
164 |
-
|
165 |
-
Configuration of select is held in the object `_select` which is attached to the
|
166 |
-
DataTables settings object on initialisation. Select being available on a table
|
167 |
-
is not optional when Select is loaded, but its default is for selection only to
|
168 |
-
be available via the API - so the end user wouldn't be able to select rows
|
169 |
-
without additional configuration.
|
170 |
-
|
171 |
-
The `_select` object contains the following properties:
|
172 |
-
|
173 |
-
```
|
174 |
-
{
|
175 |
-
items:string - Can be `rows`, `columns` or `cells`. Defines what item
|
176 |
-
will be selected if the user is allowed to activate row
|
177 |
-
selection using the mouse.
|
178 |
-
style:string - Can be `none`, `single`, `multi` or `os`. Defines the
|
179 |
-
interaction style when selecting items
|
180 |
-
blurable:boolean - If row selection can be cleared by clicking outside of
|
181 |
-
the table
|
182 |
-
info:boolean - If the selection summary should be shown in the table
|
183 |
-
information elements
|
184 |
-
}
|
185 |
-
```
|
186 |
-
|
187 |
-
In addition to the API methods, Select also extends the DataTables selector
|
188 |
-
options for rows, columns and cells adding a `selected` option to the selector
|
189 |
-
options object, allowing the developer to select only selected items or
|
190 |
-
unselected items.
|
191 |
-
|
192 |
-
## Mouse selection of items
|
193 |
-
|
194 |
-
Clicking on items can be used to select items. This is done by a simple event
|
195 |
-
handler that will select the items using the API methods.
|
196 |
-
|
197 |
-
*/
|
198 |
-
|
199 |
-
|
200 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
201 |
-
* Local functions
|
202 |
-
*/
|
203 |
-
|
204 |
-
/**
|
205 |
-
* Add one or more cells to the selection when shift clicking in OS selection
|
206 |
-
* style cell selection.
|
207 |
-
*
|
208 |
-
* Cell range is more complicated than row and column as we want to select
|
209 |
-
* in the visible grid rather than by index in sequence. For example, if you
|
210 |
-
* click first in cell 1-1 and then shift click in 2-2 - cells 1-2 and 2-1
|
211 |
-
* should also be selected (and not 1-3, 1-4. etc)
|
212 |
-
*
|
213 |
-
* @param {DataTable.Api} dt DataTable
|
214 |
-
* @param {object} idx Cell index to select to
|
215 |
-
* @param {object} last Cell index to select from
|
216 |
-
* @private
|
217 |
-
*/
|
218 |
-
function cellRange( dt, idx, last )
|
219 |
-
{
|
220 |
-
var indexes;
|
221 |
-
var columnIndexes;
|
222 |
-
var rowIndexes;
|
223 |
-
var selectColumns = function ( start, end ) {
|
224 |
-
if ( start > end ) {
|
225 |
-
var tmp = end;
|
226 |
-
end = start;
|
227 |
-
start = tmp;
|
228 |
-
}
|
229 |
-
|
230 |
-
var record = false;
|
231 |
-
return dt.columns( ':visible' ).indexes().filter( function (i) {
|
232 |
-
if ( i === start ) {
|
233 |
-
record = true;
|
234 |
-
}
|
235 |
-
|
236 |
-
if ( i === end ) { // not else if, as start might === end
|
237 |
-
record = false;
|
238 |
-
return true;
|
239 |
-
}
|
240 |
-
|
241 |
-
return record;
|
242 |
-
} );
|
243 |
-
};
|
244 |
-
|
245 |
-
var selectRows = function ( start, end ) {
|
246 |
-
var indexes = dt.rows( { search: 'applied' } ).indexes();
|
247 |
-
|
248 |
-
// Which comes first - might need to swap
|
249 |
-
if ( indexes.indexOf( start ) > indexes.indexOf( end ) ) {
|
250 |
-
var tmp = end;
|
251 |
-
end = start;
|
252 |
-
start = tmp;
|
253 |
-
}
|
254 |
-
|
255 |
-
var record = false;
|
256 |
-
return indexes.filter( function (i) {
|
257 |
-
if ( i === start ) {
|
258 |
-
record = true;
|
259 |
-
}
|
260 |
-
|
261 |
-
if ( i === end ) {
|
262 |
-
record = false;
|
263 |
-
return true;
|
264 |
-
}
|
265 |
-
|
266 |
-
return record;
|
267 |
-
} );
|
268 |
-
};
|
269 |
-
|
270 |
-
if ( ! dt.cells( { selected: true } ).any() && ! last ) {
|
271 |
-
// select from the top left cell to this one
|
272 |
-
columnIndexes = selectColumns( 0, idx.column );
|
273 |
-
rowIndexes = selectRows( 0 , idx.row );
|
274 |
-
}
|
275 |
-
else {
|
276 |
-
// Get column indexes between old and new
|
277 |
-
columnIndexes = selectColumns( last.column, idx.column );
|
278 |
-
rowIndexes = selectRows( last.row , idx.row );
|
279 |
-
}
|
280 |
-
|
281 |
-
indexes = dt.cells( rowIndexes, columnIndexes ).flatten();
|
282 |
-
|
283 |
-
if ( ! dt.cells( idx, { selected: true } ).any() ) {
|
284 |
-
// Select range
|
285 |
-
dt.cells( indexes ).select();
|
286 |
-
}
|
287 |
-
else {
|
288 |
-
// Deselect range
|
289 |
-
dt.cells( indexes ).deselect();
|
290 |
-
}
|
291 |
-
}
|
292 |
-
|
293 |
-
/**
|
294 |
-
* Disable mouse selection by removing the selectors
|
295 |
-
*
|
296 |
-
* @param {DataTable.Api} dt DataTable to remove events from
|
297 |
-
* @private
|
298 |
-
*/
|
299 |
-
function disableMouseSelection( dt )
|
300 |
-
{
|
301 |
-
var ctx = dt.settings()[0];
|
302 |
-
var selector = ctx._select.selector;
|
303 |
-
|
304 |
-
$( dt.table().body() )
|
305 |
-
.off( 'mousedown.dtSelect', selector )
|
306 |
-
.off( 'mouseup.dtSelect', selector )
|
307 |
-
.off( 'click.dtSelect', selector );
|
308 |
-
|
309 |
-
$('body').off( 'click.dtSelect' );
|
310 |
-
}
|
311 |
-
|
312 |
-
/**
|
313 |
-
* Attach mouse listeners to the table to allow mouse selection of items
|
314 |
-
*
|
315 |
-
* @param {DataTable.Api} dt DataTable to remove events from
|
316 |
-
* @private
|
317 |
-
*/
|
318 |
-
function enableMouseSelection ( dt )
|
319 |
-
{
|
320 |
-
var body = $( dt.table().body() );
|
321 |
-
var ctx = dt.settings()[0];
|
322 |
-
var selector = ctx._select.selector;
|
323 |
-
|
324 |
-
body
|
325 |
-
.on( 'mousedown.dtSelect', selector, function(e) {
|
326 |
-
// Disallow text selection for shift clicking on the table so multi
|
327 |
-
// element selection doesn't look terrible!
|
328 |
-
if ( e.shiftKey || e.metaKey || e.ctrlKey ) {
|
329 |
-
body
|
330 |
-
.css( '-moz-user-select', 'none' )
|
331 |
-
.one('selectstart.dtSelect', selector, function () {
|
332 |
-
return false;
|
333 |
-
} );
|
334 |
-
}
|
335 |
-
} )
|
336 |
-
.on( 'mouseup.dtSelect', selector, function() {
|
337 |
-
// Allow text selection to occur again, Mozilla style (tested in FF
|
338 |
-
// 35.0.1 - still required)
|
339 |
-
body.css( '-moz-user-select', '' );
|
340 |
-
} )
|
341 |
-
.on( 'click.dtSelect', selector, function ( e ) {
|
342 |
-
var items = dt.select.items();
|
343 |
-
var idx;
|
344 |
-
|
345 |
-
// If text was selected (click and drag), then we shouldn't change
|
346 |
-
// the row's selected state
|
347 |
-
if ( window.getSelection && window.getSelection().toString() ) {
|
348 |
-
return;
|
349 |
-
}
|
350 |
-
|
351 |
-
var ctx = dt.settings()[0];
|
352 |
-
|
353 |
-
// Ignore clicks inside a sub-table
|
354 |
-
if ( $(e.target).closest('div.dataTables_wrapper')[0] != dt.table().container() ) {
|
355 |
-
return;
|
356 |
-
}
|
357 |
-
|
358 |
-
var cell = dt.cell( $(e.target).closest('td, th') );
|
359 |
-
|
360 |
-
// Check the cell actually belongs to the host DataTable (so child
|
361 |
-
// rows, etc, are ignored)
|
362 |
-
if ( ! cell.any() ) {
|
363 |
-
return;
|
364 |
-
}
|
365 |
-
|
366 |
-
var event = $.Event('user-select.dt');
|
367 |
-
eventTrigger( dt, event, [ items, cell, e ] );
|
368 |
-
|
369 |
-
if ( event.isDefaultPrevented() ) {
|
370 |
-
return;
|
371 |
-
}
|
372 |
-
|
373 |
-
var cellIndex = cell.index();
|
374 |
-
if ( items === 'row' ) {
|
375 |
-
idx = cellIndex.row;
|
376 |
-
typeSelect( e, dt, ctx, 'row', idx );
|
377 |
-
}
|
378 |
-
else if ( items === 'column' ) {
|
379 |
-
idx = cell.index().column;
|
380 |
-
typeSelect( e, dt, ctx, 'column', idx );
|
381 |
-
}
|
382 |
-
else if ( items === 'cell' ) {
|
383 |
-
idx = cell.index();
|
384 |
-
typeSelect( e, dt, ctx, 'cell', idx );
|
385 |
-
}
|
386 |
-
|
387 |
-
ctx._select_lastCell = cellIndex;
|
388 |
-
} );
|
389 |
-
|
390 |
-
// Blurable
|
391 |
-
$('body').on( 'click.dtSelect', function ( e ) {
|
392 |
-
if ( ctx._select.blurable ) {
|
393 |
-
// If the click was inside the DataTables container, don't blur
|
394 |
-
if ( $(e.target).parents().filter( dt.table().container() ).length ) {
|
395 |
-
return;
|
396 |
-
}
|
397 |
-
|
398 |
-
// Don't blur in Editor form
|
399 |
-
if ( $(e.target).parents('div.DTE').length ) {
|
400 |
-
return;
|
401 |
-
}
|
402 |
-
|
403 |
-
clear( ctx, true );
|
404 |
-
}
|
405 |
-
} );
|
406 |
-
}
|
407 |
-
|
408 |
-
/**
|
409 |
-
* Trigger an event on a DataTable
|
410 |
-
*
|
411 |
-
* @param {DataTable.Api} api DataTable to trigger events on
|
412 |
-
* @param {boolean} selected true if selected, false if deselected
|
413 |
-
* @param {string} type Item type acting on
|
414 |
-
* @param {boolean} any Require that there are values before
|
415 |
-
* triggering
|
416 |
-
* @private
|
417 |
-
*/
|
418 |
-
function eventTrigger ( api, type, args, any )
|
419 |
-
{
|
420 |
-
if ( any && ! api.flatten().length ) {
|
421 |
-
return;
|
422 |
-
}
|
423 |
-
|
424 |
-
if ( typeof type === 'string' ) {
|
425 |
-
type = type +'.dt';
|
426 |
-
}
|
427 |
-
|
428 |
-
args.unshift( api );
|
429 |
-
|
430 |
-
$(api.table().node()).triggerHandler( type, args );
|
431 |
-
}
|
432 |
-
|
433 |
-
/**
|
434 |
-
* Update the information element of the DataTable showing information about the
|
435 |
-
* items selected. This is done by adding tags to the existing text
|
436 |
-
*
|
437 |
-
* @param {DataTable.Api} api DataTable to update
|
438 |
-
* @private
|
439 |
-
*/
|
440 |
-
function info ( api )
|
441 |
-
{
|
442 |
-
var ctx = api.settings()[0];
|
443 |
-
|
444 |
-
if ( ! ctx._select.info || ! ctx.aanFeatures.i ) {
|
445 |
-
return;
|
446 |
-
}
|
447 |
-
|
448 |
-
var output = $('<span class="select-info"/>');
|
449 |
-
var add = function ( name, num ) {
|
450 |
-
output.append( $('<span class="select-item"/>').append( api.i18n(
|
451 |
-
'select.'+name+'s',
|
452 |
-
{ _: '%d '+name+'s selected', 0: '', 1: '1 '+name+' selected' },
|
453 |
-
num
|
454 |
-
) ) );
|
455 |
-
};
|
456 |
-
|
457 |
-
add( 'row', api.rows( { selected: true } ).flatten().length );
|
458 |
-
add( 'column', api.columns( { selected: true } ).flatten().length );
|
459 |
-
add( 'cell', api.cells( { selected: true } ).flatten().length );
|
460 |
-
|
461 |
-
// Internal knowledge of DataTables to loop over all information elements
|
462 |
-
$.each( ctx.aanFeatures.i, function ( i, el ) {
|
463 |
-
el = $(el);
|
464 |
-
|
465 |
-
var exisiting = el.children('span.select-info');
|
466 |
-
if ( exisiting.length ) {
|
467 |
-
exisiting.remove();
|
468 |
-
}
|
469 |
-
|
470 |
-
if ( output.text() !== '' ) {
|
471 |
-
el.append( output );
|
472 |
-
}
|
473 |
-
} );
|
474 |
-
}
|
475 |
-
|
476 |
-
/**
|
477 |
-
* Initialisation of a new table. Attach event handlers and callbacks to allow
|
478 |
-
* Select to operate correctly.
|
479 |
-
*
|
480 |
-
* This will occur _after_ the initial DataTables initialisation, although
|
481 |
-
* before Ajax data is rendered, if there is ajax data
|
482 |
-
*
|
483 |
-
* @param {DataTable.settings} ctx Settings object to operate on
|
484 |
-
* @private
|
485 |
-
*/
|
486 |
-
function init ( ctx ) {
|
487 |
-
var api = new DataTable.Api( ctx );
|
488 |
-
|
489 |
-
// Row callback so that classes can be added to rows and cells if the item
|
490 |
-
// was selected before the element was created. This will happen with the
|
491 |
-
// `deferRender` option enabled.
|
492 |
-
//
|
493 |
-
// This method of attaching to `aoRowCreatedCallback` is a hack until
|
494 |
-
// DataTables has proper events for row manipulation If you are reviewing
|
495 |
-
// this code to create your own plug-ins, please do not do this!
|
496 |
-
ctx.aoRowCreatedCallback.push( {
|
497 |
-
fn: function ( row, data, index ) {
|
498 |
-
var i, ien;
|
499 |
-
var d = ctx.aoData[ index ];
|
500 |
-
|
501 |
-
// Row
|
502 |
-
if ( d._select_selected ) {
|
503 |
-
$( row ).addClass( ctx._select.className );
|
504 |
-
}
|
505 |
-
|
506 |
-
// Cells and columns - if separated out, we would need to do two
|
507 |
-
// loops, so it makes sense to combine them into a single one
|
508 |
-
for ( i=0, ien=ctx.aoColumns.length ; i<ien ; i++ ) {
|
509 |
-
if ( ctx.aoColumns[i]._select_selected || (d._selected_cells && d._selected_cells[i]) ) {
|
510 |
-
$(d.anCells[i]).addClass( ctx._select.className );
|
511 |
-
}
|
512 |
-
}
|
513 |
-
},
|
514 |
-
sName: 'select-deferRender'
|
515 |
-
} );
|
516 |
-
|
517 |
-
// On Ajax reload we want to reselect all rows which are currently selected,
|
518 |
-
// if there is an rowId (i.e. a unique value to identify each row with)
|
519 |
-
api.on( 'preXhr.dt.dtSelect', function () {
|
520 |
-
// note that column selection doesn't need to be cached and then
|
521 |
-
// reselected, as they are already selected
|
522 |
-
var rows = api.rows( { selected: true } ).ids( true ).filter( function ( d ) {
|
523 |
-
return d !== undefined;
|
524 |
-
} );
|
525 |
-
|
526 |
-
var cells = api.cells( { selected: true } ).eq(0).map( function ( cellIdx ) {
|
527 |
-
var id = api.row( cellIdx.row ).id( true );
|
528 |
-
return id ?
|
529 |
-
{ row: id, column: cellIdx.column } :
|
530 |
-
undefined;
|
531 |
-
} ).filter( function ( d ) {
|
532 |
-
return d !== undefined;
|
533 |
-
} );
|
534 |
-
|
535 |
-
// On the next draw, reselect the currently selected items
|
536 |
-
api.one( 'draw.dt.dtSelect', function () {
|
537 |
-
api.rows( rows ).select();
|
538 |
-
|
539 |
-
// `cells` is not a cell index selector, so it needs a loop
|
540 |
-
if ( cells.any() ) {
|
541 |
-
cells.each( function ( id ) {
|
542 |
-
api.cells( id.row, id.column ).select();
|
543 |
-
} );
|
544 |
-
}
|
545 |
-
} );
|
546 |
-
} );
|
547 |
-
|
548 |
-
// Update the table information element with selected item summary
|
549 |
-
api.on( 'draw.dtSelect.dt select.dtSelect.dt deselect.dtSelect.dt info.dt', function () {
|
550 |
-
info( api );
|
551 |
-
} );
|
552 |
-
|
553 |
-
// Clean up and release
|
554 |
-
api.on( 'destroy.dtSelect', function () {
|
555 |
-
disableMouseSelection( api );
|
556 |
-
api.off( '.dtSelect' );
|
557 |
-
} );
|
558 |
-
}
|
559 |
-
|
560 |
-
/**
|
561 |
-
* Add one or more items (rows or columns) to the selection when shift clicking
|
562 |
-
* in OS selection style
|
563 |
-
*
|
564 |
-
* @param {DataTable.Api} dt DataTable
|
565 |
-
* @param {string} type Row or column range selector
|
566 |
-
* @param {object} idx Item index to select to
|
567 |
-
* @param {object} last Item index to select from
|
568 |
-
* @private
|
569 |
-
*/
|
570 |
-
function rowColumnRange( dt, type, idx, last )
|
571 |
-
{
|
572 |
-
// Add a range of rows from the last selected row to this one
|
573 |
-
var indexes = dt[type+'s']( { search: 'applied' } ).indexes();
|
574 |
-
var idx1 = $.inArray( last, indexes );
|
575 |
-
var idx2 = $.inArray( idx, indexes );
|
576 |
-
|
577 |
-
if ( ! dt[type+'s']( { selected: true } ).any() && idx1 === -1 ) {
|
578 |
-
// select from top to here - slightly odd, but both Windows and Mac OS
|
579 |
-
// do this
|
580 |
-
indexes.splice( $.inArray( idx, indexes )+1, indexes.length );
|
581 |
-
}
|
582 |
-
else {
|
583 |
-
// reverse so we can shift click 'up' as well as down
|
584 |
-
if ( idx1 > idx2 ) {
|
585 |
-
var tmp = idx2;
|
586 |
-
idx2 = idx1;
|
587 |
-
idx1 = tmp;
|
588 |
-
}
|
589 |
-
|
590 |
-
indexes.splice( idx2+1, indexes.length );
|
591 |
-
indexes.splice( 0, idx1 );
|
592 |
-
}
|
593 |
-
|
594 |
-
if ( ! dt[type]( idx, { selected: true } ).any() ) {
|
595 |
-
// Select range
|
596 |
-
dt[type+'s']( indexes ).select();
|
597 |
-
}
|
598 |
-
else {
|
599 |
-
// Deselect range - need to keep the clicked on row selected
|
600 |
-
indexes.splice( $.inArray( idx, indexes ), 1 );
|
601 |
-
dt[type+'s']( indexes ).deselect();
|
602 |
-
}
|
603 |
-
}
|
604 |
-
|
605 |
-
/**
|
606 |
-
* Clear all selected items
|
607 |
-
*
|
608 |
-
* @param {DataTable.settings} ctx Settings object of the host DataTable
|
609 |
-
* @param {boolean} [force=false] Force the de-selection to happen, regardless
|
610 |
-
* of selection style
|
611 |
-
* @private
|
612 |
-
*/
|
613 |
-
function clear( ctx, force )
|
614 |
-
{
|
615 |
-
if ( force || ctx._select.style === 'single' ) {
|
616 |
-
var api = new DataTable.Api( ctx );
|
617 |
-
|
618 |
-
api.rows( { selected: true } ).deselect();
|
619 |
-
api.columns( { selected: true } ).deselect();
|
620 |
-
api.cells( { selected: true } ).deselect();
|
621 |
-
}
|
622 |
-
}
|
623 |
-
|
624 |
-
/**
|
625 |
-
* Select items based on the current configuration for style and items.
|
626 |
-
*
|
627 |
-
* @param {object} e Mouse event object
|
628 |
-
* @param {DataTables.Api} dt DataTable
|
629 |
-
* @param {DataTable.settings} ctx Settings object of the host DataTable
|
630 |
-
* @param {string} type Items to select
|
631 |
-
* @param {int|object} idx Index of the item to select
|
632 |
-
* @private
|
633 |
-
*/
|
634 |
-
function typeSelect ( e, dt, ctx, type, idx )
|
635 |
-
{
|
636 |
-
var style = dt.select.style();
|
637 |
-
var isSelected = dt[type]( idx, { selected: true } ).any();
|
638 |
-
|
639 |
-
if ( style === 'os' ) {
|
640 |
-
if ( e.ctrlKey || e.metaKey ) {
|
641 |
-
// Add or remove from the selection
|
642 |
-
dt[type]( idx ).select( ! isSelected );
|
643 |
-
}
|
644 |
-
else if ( e.shiftKey ) {
|
645 |
-
if ( type === 'cell' ) {
|
646 |
-
cellRange( dt, idx, ctx._select_lastCell || null );
|
647 |
-
}
|
648 |
-
else {
|
649 |
-
rowColumnRange( dt, type, idx, ctx._select_lastCell ?
|
650 |
-
ctx._select_lastCell[type] :
|
651 |
-
null
|
652 |
-
);
|
653 |
-
}
|
654 |
-
}
|
655 |
-
else {
|
656 |
-
// No cmd or shift click - deselect if selected, or select
|
657 |
-
// this row only
|
658 |
-
var selected = dt[type+'s']( { selected: true } );
|
659 |
-
|
660 |
-
if ( isSelected && selected.flatten().length === 1 ) {
|
661 |
-
dt[type]( idx ).deselect();
|
662 |
-
}
|
663 |
-
else {
|
664 |
-
selected.deselect();
|
665 |
-
dt[type]( idx ).select();
|
666 |
-
}
|
667 |
-
}
|
668 |
-
} else if ( style == 'multi+shift' ) {
|
669 |
-
if ( e.shiftKey ) {
|
670 |
-
if ( type === 'cell' ) {
|
671 |
-
cellRange( dt, idx, ctx._select_lastCell || null );
|
672 |
-
}
|
673 |
-
else {
|
674 |
-
rowColumnRange( dt, type, idx, ctx._select_lastCell ?
|
675 |
-
ctx._select_lastCell[type] :
|
676 |
-
null
|
677 |
-
);
|
678 |
-
}
|
679 |
-
}
|
680 |
-
else {
|
681 |
-
dt[ type ]( idx ).select( ! isSelected );
|
682 |
-
}
|
683 |
-
}
|
684 |
-
else {
|
685 |
-
dt[ type ]( idx ).select( ! isSelected );
|
686 |
-
}
|
687 |
-
}
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
692 |
-
* DataTables selectors
|
693 |
-
*/
|
694 |
-
|
695 |
-
// row and column are basically identical just assigned to different properties
|
696 |
-
// and checking a different array, so we can dynamically create the functions to
|
697 |
-
// reduce the code size
|
698 |
-
$.each( [
|
699 |
-
{ type: 'row', prop: 'aoData' },
|
700 |
-
{ type: 'column', prop: 'aoColumns' }
|
701 |
-
], function ( i, o ) {
|
702 |
-
DataTable.ext.selector[ o.type ].push( function ( settings, opts, indexes ) {
|
703 |
-
var selected = opts.selected;
|
704 |
-
var data;
|
705 |
-
var out = [];
|
706 |
-
|
707 |
-
if ( selected === undefined ) {
|
708 |
-
return indexes;
|
709 |
-
}
|
710 |
-
|
711 |
-
for ( var i=0, ien=indexes.length ; i<ien ; i++ ) {
|
712 |
-
data = settings[ o.prop ][ indexes[i] ];
|
713 |
-
|
714 |
-
if ( (selected === true && data._select_selected === true) ||
|
715 |
-
(selected === false && ! data._select_selected )
|
716 |
-
) {
|
717 |
-
out.push( indexes[i] );
|
718 |
-
}
|
719 |
-
}
|
720 |
-
|
721 |
-
return out;
|
722 |
-
} );
|
723 |
-
} );
|
724 |
-
|
725 |
-
DataTable.ext.selector.cell.push( function ( settings, opts, cells ) {
|
726 |
-
var selected = opts.selected;
|
727 |
-
var rowData;
|
728 |
-
var out = [];
|
729 |
-
|
730 |
-
if ( selected === undefined ) {
|
731 |
-
return cells;
|
732 |
-
}
|
733 |
-
|
734 |
-
for ( var i=0, ien=cells.length ; i<ien ; i++ ) {
|
735 |
-
rowData = settings.aoData[ cells[i].row ];
|
736 |
-
|
737 |
-
if ( (selected === true && rowData._selected_cells && rowData._selected_cells[ cells[i].column ] === true) ||
|
738 |
-
(selected === false && ( ! rowData._selected_cells || ! rowData._selected_cells[ cells[i].column ] ) )
|
739 |
-
) {
|
740 |
-
out.push( cells[i] );
|
741 |
-
}
|
742 |
-
}
|
743 |
-
|
744 |
-
return out;
|
745 |
-
} );
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
750 |
-
* DataTables API
|
751 |
-
*
|
752 |
-
* For complete documentation, please refer to the docs/api directory or the
|
753 |
-
* DataTables site
|
754 |
-
*/
|
755 |
-
|
756 |
-
// Local variables to improve compression
|
757 |
-
var apiRegister = DataTable.Api.register;
|
758 |
-
var apiRegisterPlural = DataTable.Api.registerPlural;
|
759 |
-
|
760 |
-
apiRegister( 'select()', function () {
|
761 |
-
return this.iterator( 'table', function ( ctx ) {
|
762 |
-
DataTable.select.init( new DataTable.Api( ctx ) );
|
763 |
-
} );
|
764 |
-
} );
|
765 |
-
|
766 |
-
apiRegister( 'select.blurable()', function ( flag ) {
|
767 |
-
if ( flag === undefined ) {
|
768 |
-
return this.context[0]._select.blurable;
|
769 |
-
}
|
770 |
-
|
771 |
-
return this.iterator( 'table', function ( ctx ) {
|
772 |
-
ctx._select.blurable = flag;
|
773 |
-
} );
|
774 |
-
} );
|
775 |
-
|
776 |
-
apiRegister( 'select.info()', function ( flag ) {
|
777 |
-
if ( info === undefined ) {
|
778 |
-
return this.context[0]._select.info;
|
779 |
-
}
|
780 |
-
|
781 |
-
return this.iterator( 'table', function ( ctx ) {
|
782 |
-
ctx._select.info = flag;
|
783 |
-
} );
|
784 |
-
} );
|
785 |
-
|
786 |
-
apiRegister( 'select.items()', function ( items ) {
|
787 |
-
if ( items === undefined ) {
|
788 |
-
return this.context[0]._select.items;
|
789 |
-
}
|
790 |
-
|
791 |
-
return this.iterator( 'table', function ( ctx ) {
|
792 |
-
ctx._select.items = items;
|
793 |
-
|
794 |
-
eventTrigger( new DataTable.Api( ctx ), 'selectItems', [ items ] );
|
795 |
-
} );
|
796 |
-
} );
|
797 |
-
|
798 |
-
// Takes effect from the _next_ selection. None disables future selection, but
|
799 |
-
// does not clear the current selection. Use the `deselect` methods for that
|
800 |
-
apiRegister( 'select.style()', function ( style ) {
|
801 |
-
if ( style === undefined ) {
|
802 |
-
return this.context[0]._select.style;
|
803 |
-
}
|
804 |
-
|
805 |
-
return this.iterator( 'table', function ( ctx ) {
|
806 |
-
ctx._select.style = style;
|
807 |
-
|
808 |
-
if ( ! ctx._select_init ) {
|
809 |
-
init( ctx );
|
810 |
-
}
|
811 |
-
|
812 |
-
// Add / remove mouse event handlers. They aren't required when only
|
813 |
-
// API selection is available
|
814 |
-
var dt = new DataTable.Api( ctx );
|
815 |
-
disableMouseSelection( dt );
|
816 |
-
|
817 |
-
if ( style !== 'api' ) {
|
818 |
-
enableMouseSelection( dt );
|
819 |
-
}
|
820 |
-
|
821 |
-
eventTrigger( new DataTable.Api( ctx ), 'selectStyle', [ style ] );
|
822 |
-
} );
|
823 |
-
} );
|
824 |
-
|
825 |
-
apiRegister( 'select.selector()', function ( selector ) {
|
826 |
-
if ( selector === undefined ) {
|
827 |
-
return this.context[0]._select.selector;
|
828 |
-
}
|
829 |
-
|
830 |
-
return this.iterator( 'table', function ( ctx ) {
|
831 |
-
disableMouseSelection( new DataTable.Api( ctx ) );
|
832 |
-
|
833 |
-
ctx._select.selector = selector;
|
834 |
-
|
835 |
-
if ( ctx._select.style !== 'api' ) {
|
836 |
-
enableMouseSelection( new DataTable.Api( ctx ) );
|
837 |
-
}
|
838 |
-
} );
|
839 |
-
} );
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
apiRegisterPlural( 'rows().select()', 'row().select()', function ( select ) {
|
844 |
-
var api = this;
|
845 |
-
|
846 |
-
if ( select === false ) {
|
847 |
-
return this.deselect();
|
848 |
-
}
|
849 |
-
|
850 |
-
this.iterator( 'row', function ( ctx, idx ) {
|
851 |
-
clear( ctx );
|
852 |
-
|
853 |
-
ctx.aoData[ idx ]._select_selected = true;
|
854 |
-
$( ctx.aoData[ idx ].nTr ).addClass( ctx._select.className );
|
855 |
-
} );
|
856 |
-
|
857 |
-
this.iterator( 'table', function ( ctx, i ) {
|
858 |
-
eventTrigger( api, 'select', [ 'row', api[i] ], true );
|
859 |
-
} );
|
860 |
-
|
861 |
-
return this;
|
862 |
-
} );
|
863 |
-
|
864 |
-
apiRegisterPlural( 'columns().select()', 'column().select()', function ( select ) {
|
865 |
-
var api = this;
|
866 |
-
|
867 |
-
if ( select === false ) {
|
868 |
-
return this.deselect();
|
869 |
-
}
|
870 |
-
|
871 |
-
this.iterator( 'column', function ( ctx, idx ) {
|
872 |
-
clear( ctx );
|
873 |
-
|
874 |
-
ctx.aoColumns[ idx ]._select_selected = true;
|
875 |
-
|
876 |
-
var column = new DataTable.Api( ctx ).column( idx );
|
877 |
-
|
878 |
-
$( column.header() ).addClass( ctx._select.className );
|
879 |
-
$( column.footer() ).addClass( ctx._select.className );
|
880 |
-
|
881 |
-
column.nodes().to$().addClass( ctx._select.className );
|
882 |
-
} );
|
883 |
-
|
884 |
-
this.iterator( 'table', function ( ctx, i ) {
|
885 |
-
eventTrigger( api, 'select', [ 'column', api[i] ], true );
|
886 |
-
} );
|
887 |
-
|
888 |
-
return this;
|
889 |
-
} );
|
890 |
-
|
891 |
-
apiRegisterPlural( 'cells().select()', 'cell().select()', function ( select ) {
|
892 |
-
var api = this;
|
893 |
-
|
894 |
-
if ( select === false ) {
|
895 |
-
return this.deselect();
|
896 |
-
}
|
897 |
-
|
898 |
-
this.iterator( 'cell', function ( ctx, rowIdx, colIdx ) {
|
899 |
-
clear( ctx );
|
900 |
-
|
901 |
-
var data = ctx.aoData[ rowIdx ];
|
902 |
-
|
903 |
-
if ( data._selected_cells === undefined ) {
|
904 |
-
data._selected_cells = [];
|
905 |
-
}
|
906 |
-
|
907 |
-
data._selected_cells[ colIdx ] = true;
|
908 |
-
|
909 |
-
if ( data.anCells ) {
|
910 |
-
$( data.anCells[ colIdx ] ).addClass( ctx._select.className );
|
911 |
-
}
|
912 |
-
} );
|
913 |
-
|
914 |
-
this.iterator( 'table', function ( ctx, i ) {
|
915 |
-
eventTrigger( api, 'select', [ 'cell', api[i] ], true );
|
916 |
-
} );
|
917 |
-
|
918 |
-
return this;
|
919 |
-
} );
|
920 |
-
|
921 |
-
|
922 |
-
apiRegisterPlural( 'rows().deselect()', 'row().deselect()', function () {
|
923 |
-
var api = this;
|
924 |
-
|
925 |
-
this.iterator( 'row', function ( ctx, idx ) {
|
926 |
-
ctx.aoData[ idx ]._select_selected = false;
|
927 |
-
$( ctx.aoData[ idx ].nTr ).removeClass( ctx._select.className );
|
928 |
-
} );
|
929 |
-
|
930 |
-
this.iterator( 'table', function ( ctx, i ) {
|
931 |
-
eventTrigger( api, 'deselect', [ 'row', api[i] ], true );
|
932 |
-
} );
|
933 |
-
|
934 |
-
return this;
|
935 |
-
} );
|
936 |
-
|
937 |
-
apiRegisterPlural( 'columns().deselect()', 'column().deselect()', function () {
|
938 |
-
var api = this;
|
939 |
-
|
940 |
-
this.iterator( 'column', function ( ctx, idx ) {
|
941 |
-
ctx.aoColumns[ idx ]._select_selected = false;
|
942 |
-
|
943 |
-
var api = new DataTable.Api( ctx );
|
944 |
-
var column = api.column( idx );
|
945 |
-
|
946 |
-
$( column.header() ).removeClass( ctx._select.className );
|
947 |
-
$( column.footer() ).removeClass( ctx._select.className );
|
948 |
-
|
949 |
-
// Need to loop over each cell, rather than just using
|
950 |
-
// `column().nodes()` as cells which are individually selected should
|
951 |
-
// not have the `selected` class removed from them
|
952 |
-
api.cells( null, idx ).indexes().each( function (cellIdx) {
|
953 |
-
var data = ctx.aoData[ cellIdx.row ];
|
954 |
-
var cellSelected = data._selected_cells;
|
955 |
-
|
956 |
-
if ( data.anCells && (! cellSelected || ! cellSelected[ cellIdx.column ]) ) {
|
957 |
-
$( data.anCells[ cellIdx.column ] ).removeClass( ctx._select.className );
|
958 |
-
}
|
959 |
-
} );
|
960 |
-
} );
|
961 |
-
|
962 |
-
this.iterator( 'table', function ( ctx, i ) {
|
963 |
-
eventTrigger( api, 'deselect', [ 'column', api[i] ], true );
|
964 |
-
} );
|
965 |
-
|
966 |
-
return this;
|
967 |
-
} );
|
968 |
-
|
969 |
-
apiRegisterPlural( 'cells().deselect()', 'cell().deselect()', function () {
|
970 |
-
var api = this;
|
971 |
-
|
972 |
-
this.iterator( 'cell', function ( ctx, rowIdx, colIdx ) {
|
973 |
-
var data = ctx.aoData[ rowIdx ];
|
974 |
-
|
975 |
-
data._selected_cells[ colIdx ] = false;
|
976 |
-
|
977 |
-
// Remove class only if the cells exist, and the cell is not column
|
978 |
-
// selected, in which case the class should remain (since it is selected
|
979 |
-
// in the column)
|
980 |
-
if ( data.anCells && ! ctx.aoColumns[ colIdx ]._select_selected ) {
|
981 |
-
$( data.anCells[ colIdx ] ).removeClass( ctx._select.className );
|
982 |
-
}
|
983 |
-
} );
|
984 |
-
|
985 |
-
this.iterator( 'table', function ( ctx, i ) {
|
986 |
-
eventTrigger( api, 'deselect', [ 'cell', api[i] ], true );
|
987 |
-
} );
|
988 |
-
|
989 |
-
return this;
|
990 |
-
} );
|
991 |
-
|
992 |
-
|
993 |
-
|
994 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
995 |
-
* Buttons
|
996 |
-
*/
|
997 |
-
function i18n( label, def ) {
|
998 |
-
return function (dt) {
|
999 |
-
return dt.i18n( 'buttons.'+label, def );
|
1000 |
-
};
|
1001 |
-
}
|
1002 |
-
|
1003 |
-
$.extend( DataTable.ext.buttons, {
|
1004 |
-
selected: {
|
1005 |
-
text: i18n( 'selected', 'Selected' ),
|
1006 |
-
className: 'buttons-selected',
|
1007 |
-
init: function ( dt ) {
|
1008 |
-
var that = this;
|
1009 |
-
|
1010 |
-
// .DT namespace listeners are removed by DataTables automatically
|
1011 |
-
// on table destroy
|
1012 |
-
dt.on( 'draw.dt.DT select.dt.DT deselect.dt.DT', function () {
|
1013 |
-
var enable = that.rows( { selected: true } ).any() ||
|
1014 |
-
that.columns( { selected: true } ).any() ||
|
1015 |
-
that.cells( { selected: true } ).any();
|
1016 |
-
|
1017 |
-
that.enable( enable );
|
1018 |
-
} );
|
1019 |
-
|
1020 |
-
this.disable();
|
1021 |
-
}
|
1022 |
-
},
|
1023 |
-
selectedSingle: {
|
1024 |
-
text: i18n( 'selectedSingle', 'Selected single' ),
|
1025 |
-
className: 'buttons-selected-single',
|
1026 |
-
init: function ( dt ) {
|
1027 |
-
var that = this;
|
1028 |
-
|
1029 |
-
dt.on( 'draw.dt.DT select.dt.DT deselect.dt.DT', function () {
|
1030 |
-
var count = dt.rows( { selected: true } ).flatten().length +
|
1031 |
-
dt.columns( { selected: true } ).flatten().length +
|
1032 |
-
dt.cells( { selected: true } ).flatten().length;
|
1033 |
-
|
1034 |
-
that.enable( count === 1 );
|
1035 |
-
} );
|
1036 |
-
|
1037 |
-
this.disable();
|
1038 |
-
}
|
1039 |
-
},
|
1040 |
-
selectAll: {
|
1041 |
-
text: i18n( 'selectAll', 'Select all' ),
|
1042 |
-
className: 'buttons-select-all',
|
1043 |
-
action: function () {
|
1044 |
-
var items = this.select.items();
|
1045 |
-
this[ items+'s' ]().select();
|
1046 |
-
}
|
1047 |
-
},
|
1048 |
-
selectNone: {
|
1049 |
-
text: i18n( 'selectNone', 'Deselect all' ),
|
1050 |
-
className: 'buttons-select-none',
|
1051 |
-
action: function () {
|
1052 |
-
clear( this.settings()[0], true );
|
1053 |
-
},
|
1054 |
-
init: function ( dt ) {
|
1055 |
-
var that = this;
|
1056 |
-
|
1057 |
-
dt.on( 'draw.dt.DT select.dt.DT deselect.dt.DT', function () {
|
1058 |
-
var count = dt.rows( { selected: true } ).flatten().length +
|
1059 |
-
dt.columns( { selected: true } ).flatten().length +
|
1060 |
-
dt.cells( { selected: true } ).flatten().length;
|
1061 |
-
|
1062 |
-
that.enable( count > 0 );
|
1063 |
-
} );
|
1064 |
-
|
1065 |
-
this.disable();
|
1066 |
-
}
|
1067 |
-
}
|
1068 |
-
} );
|
1069 |
-
|
1070 |
-
$.each( [ 'Row', 'Column', 'Cell' ], function ( i, item ) {
|
1071 |
-
var lc = item.toLowerCase();
|
1072 |
-
|
1073 |
-
DataTable.ext.buttons[ 'select'+item+'s' ] = {
|
1074 |
-
text: i18n( 'select'+item+'s', 'Select '+lc+'s' ),
|
1075 |
-
className: 'buttons-select-'+lc+'s',
|
1076 |
-
action: function () {
|
1077 |
-
this.select.items( lc );
|
1078 |
-
},
|
1079 |
-
init: function ( dt ) {
|
1080 |
-
var that = this;
|
1081 |
-
|
1082 |
-
dt.on( 'selectItems.dt.DT', function ( e, ctx, items ) {
|
1083 |
-
that.active( items === lc );
|
1084 |
-
} );
|
1085 |
-
}
|
1086 |
-
};
|
1087 |
-
} );
|
1088 |
-
|
1089 |
-
|
1090 |
-
|
1091 |
-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
1092 |
-
* Initialisation
|
1093 |
-
*/
|
1094 |
-
|
1095 |
-
// DataTables creation - check if select has been defined in the options. Note
|
1096 |
-
// this required that the table be in the document! If it isn't then something
|
1097 |
-
// needs to trigger this method unfortunately. The next major release of
|
1098 |
-
// DataTables will rework the events and address this.
|
1099 |
-
$(document).on( 'preInit.dt.dtSelect', function (e, ctx) {
|
1100 |
-
if ( e.namespace !== 'dt' ) {
|
1101 |
-
return;
|
1102 |
-
}
|
1103 |
-
|
1104 |
-
DataTable.select.init( new DataTable.Api( ctx ) );
|
1105 |
-
} );
|
1106 |
-
|
1107 |
-
|
1108 |
-
return DataTable.select;
|
1109 |
-
}));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/extensions/Select/js/dataTables.select.min.js
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
/*!
|
2 |
-
Select for DataTables 1.2.0
|
3 |
-
2015-2016 SpryMedia Ltd - datatables.net/license/mit
|
4 |
-
*/
|
5 |
-
(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(i){return e(i,window,document)}):"object"===typeof exports?module.exports=function(i,l){i||(i=window);if(!l||!l.fn.dataTable)l=require("datatables.net")(i,l).$;return e(l,i,i.document)}:e(jQuery,window,document)})(function(e,i,l,h){function t(b,a,c){var d;d=function(c,a){if(c>a)var d=a,a=c,c=d;var f=!1;return b.columns(":visible").indexes().filter(function(b){b===c&&(f=!0);return b===a?(f=!1,!0):f})};var f=
|
6 |
-
function(c,a){var d=b.rows({search:"applied"}).indexes();if(d.indexOf(c)>d.indexOf(a))var f=a,a=c,c=f;var e=!1;return d.filter(function(b){b===c&&(e=!0);return b===a?(e=!1,!0):e})};!b.cells({selected:!0}).any()&&!c?(d=d(0,a.column),c=f(0,a.row)):(d=d(c.column,a.column),c=f(c.row,a.row));c=b.cells(c,d).flatten();b.cells(a,{selected:!0}).any()?b.cells(c).deselect():b.cells(c).select()}function r(b){var a=b.settings()[0]._select.selector;e(b.table().body()).off("mousedown.dtSelect",a).off("mouseup.dtSelect",
|
7 |
-
a).off("click.dtSelect",a);e("body").off("click.dtSelect")}function v(b){var a=e(b.table().body()),c=b.settings()[0],d=c._select.selector;a.on("mousedown.dtSelect",d,function(c){if(c.shiftKey||c.metaKey||c.ctrlKey)a.css("-moz-user-select","none").one("selectstart.dtSelect",d,function(){return!1})}).on("mouseup.dtSelect",d,function(){a.css("-moz-user-select","")}).on("click.dtSelect",d,function(c){var a=b.select.items();if(!i.getSelection||!i.getSelection().toString()){var d=b.settings()[0];if(e(c.target).closest("div.dataTables_wrapper")[0]==
|
8 |
-
b.table().container()){var g=b.cell(e(c.target).closest("td, th"));if(g.any()){var h=e.Event("user-select.dt");k(b,h,[a,g,c]);h.isDefaultPrevented()||(h=g.index(),"row"===a?(a=h.row,s(c,b,d,"row",a)):"column"===a?(a=g.index().column,s(c,b,d,"column",a)):"cell"===a&&(a=g.index(),s(c,b,d,"cell",a)),d._select_lastCell=h)}}}});e("body").on("click.dtSelect",function(a){c._select.blurable&&!e(a.target).parents().filter(b.table().container()).length&&(e(a.target).parents("div.DTE").length||p(c,!0))})}function k(b,
|
9 |
-
a,c,d){if(!d||b.flatten().length)"string"===typeof a&&(a+=".dt"),c.unshift(b),e(b.table().node()).triggerHandler(a,c)}function w(b){var a=b.settings()[0];if(a._select.info&&a.aanFeatures.i){var c=e('<span class="select-info"/>'),d=function(a,d){c.append(e('<span class="select-item"/>').append(b.i18n("select."+a+"s",{_:"%d "+a+"s selected","0":"",1:"1 "+a+" selected"},d)))};d("row",b.rows({selected:!0}).flatten().length);d("column",b.columns({selected:!0}).flatten().length);d("cell",b.cells({selected:!0}).flatten().length);
|
10 |
-
e.each(a.aanFeatures.i,function(a,b){var b=e(b),d=b.children("span.select-info");d.length&&d.remove();""!==c.text()&&b.append(c)})}}function x(b,a,c,d){var f=b[a+"s"]({search:"applied"}).indexes(),d=e.inArray(d,f),m=e.inArray(c,f);if(!b[a+"s"]({selected:!0}).any()&&-1===d)f.splice(e.inArray(c,f)+1,f.length);else{if(d>m)var j=m,m=d,d=j;f.splice(m+1,f.length);f.splice(0,d)}b[a](c,{selected:!0}).any()?(f.splice(e.inArray(c,f),1),b[a+"s"](f).deselect()):b[a+"s"](f).select()}function p(b,a){if(a||"single"===
|
11 |
-
b._select.style){var c=new g.Api(b);c.rows({selected:!0}).deselect();c.columns({selected:!0}).deselect();c.cells({selected:!0}).deselect()}}function s(b,a,c,d,f){var e=a.select.style(),j=a[d](f,{selected:!0}).any();"os"===e?b.ctrlKey||b.metaKey?a[d](f).select(!j):b.shiftKey?"cell"===d?t(a,f,c._select_lastCell||null):x(a,d,f,c._select_lastCell?c._select_lastCell[d]:null):(b=a[d+"s"]({selected:!0}),j&&1===b.flatten().length?a[d](f).deselect():(b.deselect(),a[d](f).select())):"multi+shift"==e?b.shiftKey?
|
12 |
-
"cell"===d?t(a,f,c._select_lastCell||null):x(a,d,f,c._select_lastCell?c._select_lastCell[d]:null):a[d](f).select(!j):a[d](f).select(!j)}function q(b,a){return function(c){return c.i18n("buttons."+b,a)}}var g=e.fn.dataTable;g.select={};g.select.version="1.2.0";g.select.init=function(b){var a=b.settings()[0],c=a.oInit.select,d=g.defaults.select,c=c===h?d:c,d="row",f="api",m=!1,j=!0,u="td, th",i="selected";a._select={};if(!0===c)f="os";else if("string"===typeof c)f=c;else if(e.isPlainObject(c)&&(c.blurable!==
|
13 |
-
h&&(m=c.blurable),c.info!==h&&(j=c.info),c.items!==h&&(d=c.items),c.style!==h&&(f=c.style),c.selector!==h&&(u=c.selector),c.className!==h))i=c.className;b.select.selector(u);b.select.items(d);b.select.style(f);b.select.blurable(m);b.select.info(j);a._select.className=i;e.fn.dataTable.ext.order["select-checkbox"]=function(a,c){return this.api().column(c,{order:"index"}).nodes().map(function(c){return"row"===a._select.items?e(c).parent().hasClass(a._select.className):"cell"===a._select.items?e(c).hasClass(a._select.className):
|
14 |
-
!1})};e(b.table().node()).hasClass("selectable")&&b.select.style("os")};e.each([{type:"row",prop:"aoData"},{type:"column",prop:"aoColumns"}],function(b,a){g.ext.selector[a.type].push(function(c,b,f){var b=b.selected,e,j=[];if(b===h)return f;for(var g=0,i=f.length;g<i;g++)e=c[a.prop][f[g]],(!0===b&&!0===e._select_selected||!1===b&&!e._select_selected)&&j.push(f[g]);return j})});g.ext.selector.cell.push(function(b,a,c){var a=a.selected,d,f=[];if(a===h)return c;for(var e=0,g=c.length;e<g;e++)d=b.aoData[c[e].row],
|
15 |
-
(!0===a&&d._selected_cells&&!0===d._selected_cells[c[e].column]||!1===a&&(!d._selected_cells||!d._selected_cells[c[e].column]))&&f.push(c[e]);return f});var n=g.Api.register,o=g.Api.registerPlural;n("select()",function(){return this.iterator("table",function(b){g.select.init(new g.Api(b))})});n("select.blurable()",function(b){return b===h?this.context[0]._select.blurable:this.iterator("table",function(a){a._select.blurable=b})});n("select.info()",function(b){return w===h?this.context[0]._select.info:
|
16 |
-
this.iterator("table",function(a){a._select.info=b})});n("select.items()",function(b){return b===h?this.context[0]._select.items:this.iterator("table",function(a){a._select.items=b;k(new g.Api(a),"selectItems",[b])})});n("select.style()",function(b){return b===h?this.context[0]._select.style:this.iterator("table",function(a){a._select.style=b;if(!a._select_init){var c=new g.Api(a);a.aoRowCreatedCallback.push({fn:function(c,b,d){b=a.aoData[d];b._select_selected&&e(c).addClass(a._select.className);
|
17 |
-
c=0;for(d=a.aoColumns.length;c<d;c++)(a.aoColumns[c]._select_selected||b._selected_cells&&b._selected_cells[c])&&e(b.anCells[c]).addClass(a._select.className)},sName:"select-deferRender"});c.on("preXhr.dt.dtSelect",function(){var a=c.rows({selected:!0}).ids(!0).filter(function(c){return c!==h}),b=c.cells({selected:!0}).eq(0).map(function(a){var b=c.row(a.row).id(!0);return b?{row:b,column:a.column}:h}).filter(function(c){return c!==h});c.one("draw.dt.dtSelect",function(){c.rows(a).select();b.any()&&
|
18 |
-
b.each(function(a){c.cells(a.row,a.column).select()})})});c.on("draw.dtSelect.dt select.dtSelect.dt deselect.dtSelect.dt info.dt",function(){w(c)});c.on("destroy.dtSelect",function(){r(c);c.off(".dtSelect")})}var d=new g.Api(a);r(d);"api"!==b&&v(d);k(new g.Api(a),"selectStyle",[b])})});n("select.selector()",function(b){return b===h?this.context[0]._select.selector:this.iterator("table",function(a){r(new g.Api(a));a._select.selector=b;"api"!==a._select.style&&v(new g.Api(a))})});o("rows().select()",
|
19 |
-
"row().select()",function(b){var a=this;if(!1===b)return this.deselect();this.iterator("row",function(c,a){p(c);c.aoData[a]._select_selected=!0;e(c.aoData[a].nTr).addClass(c._select.className)});this.iterator("table",function(c,b){k(a,"select",["row",a[b]],!0)});return this});o("columns().select()","column().select()",function(b){var a=this;if(!1===b)return this.deselect();this.iterator("column",function(a,b){p(a);a.aoColumns[b]._select_selected=!0;var f=(new g.Api(a)).column(b);e(f.header()).addClass(a._select.className);
|
20 |
-
e(f.footer()).addClass(a._select.className);f.nodes().to$().addClass(a._select.className)});this.iterator("table",function(c,b){k(a,"select",["column",a[b]],!0)});return this});o("cells().select()","cell().select()",function(b){var a=this;if(!1===b)return this.deselect();this.iterator("cell",function(a,b,f){p(a);b=a.aoData[b];b._selected_cells===h&&(b._selected_cells=[]);b._selected_cells[f]=!0;b.anCells&&e(b.anCells[f]).addClass(a._select.className)});this.iterator("table",function(b,d){k(a,"select",
|
21 |
-
["cell",a[d]],!0)});return this});o("rows().deselect()","row().deselect()",function(){var b=this;this.iterator("row",function(a,b){a.aoData[b]._select_selected=!1;e(a.aoData[b].nTr).removeClass(a._select.className)});this.iterator("table",function(a,c){k(b,"deselect",["row",b[c]],!0)});return this});o("columns().deselect()","column().deselect()",function(){var b=this;this.iterator("column",function(a,b){a.aoColumns[b]._select_selected=!1;var d=new g.Api(a),f=d.column(b);e(f.header()).removeClass(a._select.className);
|
22 |
-
e(f.footer()).removeClass(a._select.className);d.cells(null,b).indexes().each(function(b){var c=a.aoData[b.row],d=c._selected_cells;c.anCells&&(!d||!d[b.column])&&e(c.anCells[b.column]).removeClass(a._select.className)})});this.iterator("table",function(a,c){k(b,"deselect",["column",b[c]],!0)});return this});o("cells().deselect()","cell().deselect()",function(){var b=this;this.iterator("cell",function(a,b,d){b=a.aoData[b];b._selected_cells[d]=!1;b.anCells&&!a.aoColumns[d]._select_selected&&e(b.anCells[d]).removeClass(a._select.className)});
|
23 |
-
this.iterator("table",function(a,c){k(b,"deselect",["cell",b[c]],!0)});return this});e.extend(g.ext.buttons,{selected:{text:q("selected","Selected"),className:"buttons-selected",init:function(b){var a=this;b.on("draw.dt.DT select.dt.DT deselect.dt.DT",function(){var b=a.rows({selected:!0}).any()||a.columns({selected:!0}).any()||a.cells({selected:!0}).any();a.enable(b)});this.disable()}},selectedSingle:{text:q("selectedSingle","Selected single"),className:"buttons-selected-single",init:function(b){var a=
|
24 |
-
this;b.on("draw.dt.DT select.dt.DT deselect.dt.DT",function(){var c=b.rows({selected:!0}).flatten().length+b.columns({selected:!0}).flatten().length+b.cells({selected:!0}).flatten().length;a.enable(1===c)});this.disable()}},selectAll:{text:q("selectAll","Select all"),className:"buttons-select-all",action:function(){this[this.select.items()+"s"]().select()}},selectNone:{text:q("selectNone","Deselect all"),className:"buttons-select-none",action:function(){p(this.settings()[0],!0)},init:function(b){var a=
|
25 |
-
this;b.on("draw.dt.DT select.dt.DT deselect.dt.DT",function(){var c=b.rows({selected:!0}).flatten().length+b.columns({selected:!0}).flatten().length+b.cells({selected:!0}).flatten().length;a.enable(0<c)});this.disable()}}});e.each(["Row","Column","Cell"],function(b,a){var c=a.toLowerCase();g.ext.buttons["select"+a+"s"]={text:q("select"+a+"s","Select "+c+"s"),className:"buttons-select-"+c+"s",action:function(){this.select.items(c)},init:function(a){var b=this;a.on("selectItems.dt.DT",function(a,d,
|
26 |
-
e){b.active(e===c)})}}});e(l).on("preInit.dt.dtSelect",function(b,a){"dt"===b.namespace&&g.select.init(new g.Api(a))});return g.select});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/media/css/jquery.dataTables.css
DELETED
@@ -1,452 +0,0 @@
|
|
1 |
-
/*
|
2 |
-
* Table styles
|
3 |
-
*/
|
4 |
-
table.dataTable {
|
5 |
-
width: 100%;
|
6 |
-
margin: 0 auto;
|
7 |
-
clear: both;
|
8 |
-
border-collapse: separate;
|
9 |
-
border-spacing: 0;
|
10 |
-
/*
|
11 |
-
* Header and footer styles
|
12 |
-
*/
|
13 |
-
/*
|
14 |
-
* Body styles
|
15 |
-
*/
|
16 |
-
}
|
17 |
-
table.dataTable thead th,
|
18 |
-
table.dataTable tfoot th {
|
19 |
-
font-weight: bold;
|
20 |
-
}
|
21 |
-
table.dataTable thead th,
|
22 |
-
table.dataTable thead td {
|
23 |
-
padding: 10px 18px;
|
24 |
-
border-bottom: 1px solid #111;
|
25 |
-
}
|
26 |
-
table.dataTable thead th:active,
|
27 |
-
table.dataTable thead td:active {
|
28 |
-
outline: none;
|
29 |
-
}
|
30 |
-
table.dataTable tfoot th,
|
31 |
-
table.dataTable tfoot td {
|
32 |
-
padding: 10px 18px 6px 18px;
|
33 |
-
border-top: 1px solid #111;
|
34 |
-
}
|
35 |
-
table.dataTable thead .sorting,
|
36 |
-
table.dataTable thead .sorting_asc,
|
37 |
-
table.dataTable thead .sorting_desc {
|
38 |
-
cursor: pointer;
|
39 |
-
*cursor: hand;
|
40 |
-
}
|
41 |
-
table.dataTable thead .sorting,
|
42 |
-
table.dataTable thead .sorting_asc,
|
43 |
-
table.dataTable thead .sorting_desc,
|
44 |
-
table.dataTable thead .sorting_asc_disabled,
|
45 |
-
table.dataTable thead .sorting_desc_disabled {
|
46 |
-
background-repeat: no-repeat;
|
47 |
-
background-position: center right;
|
48 |
-
}
|
49 |
-
table.dataTable thead .sorting {
|
50 |
-
background-image: url("../images/sort_both.png");
|
51 |
-
}
|
52 |
-
table.dataTable thead .sorting_asc {
|
53 |
-
background-image: url("../images/sort_asc.png");
|
54 |
-
}
|
55 |
-
table.dataTable thead .sorting_desc {
|
56 |
-
background-image: url("../images/sort_desc.png");
|
57 |
-
}
|
58 |
-
table.dataTable thead .sorting_asc_disabled {
|
59 |
-
background-image: url("../images/sort_asc_disabled.png");
|
60 |
-
}
|
61 |
-
table.dataTable thead .sorting_desc_disabled {
|
62 |
-
background-image: url("../images/sort_desc_disabled.png");
|
63 |
-
}
|
64 |
-
table.dataTable tbody tr {
|
65 |
-
background-color: #ffffff;
|
66 |
-
}
|
67 |
-
table.dataTable tbody tr.selected {
|
68 |
-
background-color: #B0BED9;
|
69 |
-
}
|
70 |
-
table.dataTable tbody th,
|
71 |
-
table.dataTable tbody td {
|
72 |
-
padding: 8px 10px;
|
73 |
-
}
|
74 |
-
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
75 |
-
border-top: 1px solid #ddd;
|
76 |
-
}
|
77 |
-
table.dataTable.row-border tbody tr:first-child th,
|
78 |
-
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
79 |
-
table.dataTable.display tbody tr:first-child td {
|
80 |
-
border-top: none;
|
81 |
-
}
|
82 |
-
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
83 |
-
border-top: 1px solid #ddd;
|
84 |
-
border-right: 1px solid #ddd;
|
85 |
-
}
|
86 |
-
table.dataTable.cell-border tbody tr th:first-child,
|
87 |
-
table.dataTable.cell-border tbody tr td:first-child {
|
88 |
-
border-left: 1px solid #ddd;
|
89 |
-
}
|
90 |
-
table.dataTable.cell-border tbody tr:first-child th,
|
91 |
-
table.dataTable.cell-border tbody tr:first-child td {
|
92 |
-
border-top: none;
|
93 |
-
}
|
94 |
-
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
95 |
-
background-color: #f9f9f9;
|
96 |
-
}
|
97 |
-
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
98 |
-
background-color: #acbad4;
|
99 |
-
}
|
100 |
-
table.dataTable.hover tbody tr:hover, table.dataTable.display tbody tr:hover {
|
101 |
-
background-color: #f6f6f6;
|
102 |
-
}
|
103 |
-
table.dataTable.hover tbody tr:hover.selected, table.dataTable.display tbody tr:hover.selected {
|
104 |
-
background-color: #aab7d1;
|
105 |
-
}
|
106 |
-
table.dataTable.order-column tbody tr > .sorting_1,
|
107 |
-
table.dataTable.order-column tbody tr > .sorting_2,
|
108 |
-
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
109 |
-
table.dataTable.display tbody tr > .sorting_2,
|
110 |
-
table.dataTable.display tbody tr > .sorting_3 {
|
111 |
-
background-color: #fafafa;
|
112 |
-
}
|
113 |
-
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
114 |
-
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
115 |
-
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
116 |
-
table.dataTable.display tbody tr.selected > .sorting_2,
|
117 |
-
table.dataTable.display tbody tr.selected > .sorting_3 {
|
118 |
-
background-color: #acbad5;
|
119 |
-
}
|
120 |
-
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
121 |
-
background-color: #f1f1f1;
|
122 |
-
}
|
123 |
-
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
124 |
-
background-color: #f3f3f3;
|
125 |
-
}
|
126 |
-
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
127 |
-
background-color: whitesmoke;
|
128 |
-
}
|
129 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
130 |
-
background-color: #a6b4cd;
|
131 |
-
}
|
132 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
133 |
-
background-color: #a8b5cf;
|
134 |
-
}
|
135 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
136 |
-
background-color: #a9b7d1;
|
137 |
-
}
|
138 |
-
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
139 |
-
background-color: #fafafa;
|
140 |
-
}
|
141 |
-
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
142 |
-
background-color: #fcfcfc;
|
143 |
-
}
|
144 |
-
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
145 |
-
background-color: #fefefe;
|
146 |
-
}
|
147 |
-
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
148 |
-
background-color: #acbad5;
|
149 |
-
}
|
150 |
-
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
151 |
-
background-color: #aebcd6;
|
152 |
-
}
|
153 |
-
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
154 |
-
background-color: #afbdd8;
|
155 |
-
}
|
156 |
-
table.dataTable.display tbody tr:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1 {
|
157 |
-
background-color: #eaeaea;
|
158 |
-
}
|
159 |
-
table.dataTable.display tbody tr:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2 {
|
160 |
-
background-color: #ececec;
|
161 |
-
}
|
162 |
-
table.dataTable.display tbody tr:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3 {
|
163 |
-
background-color: #efefef;
|
164 |
-
}
|
165 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1 {
|
166 |
-
background-color: #a2aec7;
|
167 |
-
}
|
168 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2 {
|
169 |
-
background-color: #a3b0c9;
|
170 |
-
}
|
171 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3 {
|
172 |
-
background-color: #a5b2cb;
|
173 |
-
}
|
174 |
-
table.dataTable.no-footer {
|
175 |
-
border-bottom: 1px solid #111;
|
176 |
-
}
|
177 |
-
table.dataTable.nowrap th, table.dataTable.nowrap td {
|
178 |
-
white-space: nowrap;
|
179 |
-
}
|
180 |
-
table.dataTable.compact thead th,
|
181 |
-
table.dataTable.compact thead td {
|
182 |
-
padding: 4px 17px 4px 4px;
|
183 |
-
}
|
184 |
-
table.dataTable.compact tfoot th,
|
185 |
-
table.dataTable.compact tfoot td {
|
186 |
-
padding: 4px;
|
187 |
-
}
|
188 |
-
table.dataTable.compact tbody th,
|
189 |
-
table.dataTable.compact tbody td {
|
190 |
-
padding: 4px;
|
191 |
-
}
|
192 |
-
table.dataTable th.dt-left,
|
193 |
-
table.dataTable td.dt-left {
|
194 |
-
text-align: left;
|
195 |
-
}
|
196 |
-
table.dataTable th.dt-center,
|
197 |
-
table.dataTable td.dt-center,
|
198 |
-
table.dataTable td.dataTables_empty {
|
199 |
-
text-align: center;
|
200 |
-
}
|
201 |
-
table.dataTable th.dt-right,
|
202 |
-
table.dataTable td.dt-right {
|
203 |
-
text-align: right;
|
204 |
-
}
|
205 |
-
table.dataTable th.dt-justify,
|
206 |
-
table.dataTable td.dt-justify {
|
207 |
-
text-align: justify;
|
208 |
-
}
|
209 |
-
table.dataTable th.dt-nowrap,
|
210 |
-
table.dataTable td.dt-nowrap {
|
211 |
-
white-space: nowrap;
|
212 |
-
}
|
213 |
-
table.dataTable thead th.dt-head-left,
|
214 |
-
table.dataTable thead td.dt-head-left,
|
215 |
-
table.dataTable tfoot th.dt-head-left,
|
216 |
-
table.dataTable tfoot td.dt-head-left {
|
217 |
-
text-align: left;
|
218 |
-
}
|
219 |
-
table.dataTable thead th.dt-head-center,
|
220 |
-
table.dataTable thead td.dt-head-center,
|
221 |
-
table.dataTable tfoot th.dt-head-center,
|
222 |
-
table.dataTable tfoot td.dt-head-center {
|
223 |
-
text-align: center;
|
224 |
-
}
|
225 |
-
table.dataTable thead th.dt-head-right,
|
226 |
-
table.dataTable thead td.dt-head-right,
|
227 |
-
table.dataTable tfoot th.dt-head-right,
|
228 |
-
table.dataTable tfoot td.dt-head-right {
|
229 |
-
text-align: right;
|
230 |
-
}
|
231 |
-
table.dataTable thead th.dt-head-justify,
|
232 |
-
table.dataTable thead td.dt-head-justify,
|
233 |
-
table.dataTable tfoot th.dt-head-justify,
|
234 |
-
table.dataTable tfoot td.dt-head-justify {
|
235 |
-
text-align: justify;
|
236 |
-
}
|
237 |
-
table.dataTable thead th.dt-head-nowrap,
|
238 |
-
table.dataTable thead td.dt-head-nowrap,
|
239 |
-
table.dataTable tfoot th.dt-head-nowrap,
|
240 |
-
table.dataTable tfoot td.dt-head-nowrap {
|
241 |
-
white-space: nowrap;
|
242 |
-
}
|
243 |
-
table.dataTable tbody th.dt-body-left,
|
244 |
-
table.dataTable tbody td.dt-body-left {
|
245 |
-
text-align: left;
|
246 |
-
}
|
247 |
-
table.dataTable tbody th.dt-body-center,
|
248 |
-
table.dataTable tbody td.dt-body-center {
|
249 |
-
text-align: center;
|
250 |
-
}
|
251 |
-
table.dataTable tbody th.dt-body-right,
|
252 |
-
table.dataTable tbody td.dt-body-right {
|
253 |
-
text-align: right;
|
254 |
-
}
|
255 |
-
table.dataTable tbody th.dt-body-justify,
|
256 |
-
table.dataTable tbody td.dt-body-justify {
|
257 |
-
text-align: justify;
|
258 |
-
}
|
259 |
-
table.dataTable tbody th.dt-body-nowrap,
|
260 |
-
table.dataTable tbody td.dt-body-nowrap {
|
261 |
-
white-space: nowrap;
|
262 |
-
}
|
263 |
-
|
264 |
-
table.dataTable,
|
265 |
-
table.dataTable th,
|
266 |
-
table.dataTable td {
|
267 |
-
-webkit-box-sizing: content-box;
|
268 |
-
box-sizing: content-box;
|
269 |
-
}
|
270 |
-
|
271 |
-
/*
|
272 |
-
* Control feature layout
|
273 |
-
*/
|
274 |
-
.dataTables_wrapper {
|
275 |
-
position: relative;
|
276 |
-
clear: both;
|
277 |
-
*zoom: 1;
|
278 |
-
zoom: 1;
|
279 |
-
}
|
280 |
-
.dataTables_wrapper .dataTables_length {
|
281 |
-
float: left;
|
282 |
-
}
|
283 |
-
.dataTables_wrapper .dataTables_filter {
|
284 |
-
float: right;
|
285 |
-
text-align: right;
|
286 |
-
}
|
287 |
-
.dataTables_wrapper .dataTables_filter input {
|
288 |
-
margin-left: 0.5em;
|
289 |
-
}
|
290 |
-
.dataTables_wrapper .dataTables_info {
|
291 |
-
clear: both;
|
292 |
-
float: left;
|
293 |
-
padding-top: 0.755em;
|
294 |
-
}
|
295 |
-
.dataTables_wrapper .dataTables_paginate {
|
296 |
-
float: right;
|
297 |
-
text-align: right;
|
298 |
-
padding-top: 0.25em;
|
299 |
-
}
|
300 |
-
.dataTables_wrapper .dataTables_paginate .paginate_button {
|
301 |
-
box-sizing: border-box;
|
302 |
-
display: inline-block;
|
303 |
-
min-width: 1.5em;
|
304 |
-
padding: 0.5em 1em;
|
305 |
-
margin-left: 2px;
|
306 |
-
text-align: center;
|
307 |
-
text-decoration: none !important;
|
308 |
-
cursor: pointer;
|
309 |
-
*cursor: hand;
|
310 |
-
color: #333 !important;
|
311 |
-
border: 1px solid transparent;
|
312 |
-
border-radius: 2px;
|
313 |
-
}
|
314 |
-
.dataTables_wrapper .dataTables_paginate .paginate_button.current, .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
|
315 |
-
color: #333 !important;
|
316 |
-
border: 1px solid #979797;
|
317 |
-
background-color: white;
|
318 |
-
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, white), color-stop(100%, #dcdcdc));
|
319 |
-
/* Chrome,Safari4+ */
|
320 |
-
background: -webkit-linear-gradient(top, white 0%, #dcdcdc 100%);
|
321 |
-
/* Chrome10+,Safari5.1+ */
|
322 |
-
background: -moz-linear-gradient(top, white 0%, #dcdcdc 100%);
|
323 |
-
/* FF3.6+ */
|
324 |
-
background: -ms-linear-gradient(top, white 0%, #dcdcdc 100%);
|
325 |
-
/* IE10+ */
|
326 |
-
background: -o-linear-gradient(top, white 0%, #dcdcdc 100%);
|
327 |
-
/* Opera 11.10+ */
|
328 |
-
background: linear-gradient(to bottom, white 0%, #dcdcdc 100%);
|
329 |
-
/* W3C */
|
330 |
-
}
|
331 |
-
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active {
|
332 |
-
cursor: default;
|
333 |
-
color: #666 !important;
|
334 |
-
border: 1px solid transparent;
|
335 |
-
background: transparent;
|
336 |
-
box-shadow: none;
|
337 |
-
}
|
338 |
-
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
|
339 |
-
color: white !important;
|
340 |
-
border: 1px solid #111;
|
341 |
-
background-color: #585858;
|
342 |
-
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #585858), color-stop(100%, #111));
|
343 |
-
/* Chrome,Safari4+ */
|
344 |
-
background: -webkit-linear-gradient(top, #585858 0%, #111 100%);
|
345 |
-
/* Chrome10+,Safari5.1+ */
|
346 |
-
background: -moz-linear-gradient(top, #585858 0%, #111 100%);
|
347 |
-
/* FF3.6+ */
|
348 |
-
background: -ms-linear-gradient(top, #585858 0%, #111 100%);
|
349 |
-
/* IE10+ */
|
350 |
-
background: -o-linear-gradient(top, #585858 0%, #111 100%);
|
351 |
-
/* Opera 11.10+ */
|
352 |
-
background: linear-gradient(to bottom, #585858 0%, #111 100%);
|
353 |
-
/* W3C */
|
354 |
-
}
|
355 |
-
.dataTables_wrapper .dataTables_paginate .paginate_button:active {
|
356 |
-
outline: none;
|
357 |
-
background-color: #2b2b2b;
|
358 |
-
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #2b2b2b), color-stop(100%, #0c0c0c));
|
359 |
-
/* Chrome,Safari4+ */
|
360 |
-
background: -webkit-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
361 |
-
/* Chrome10+,Safari5.1+ */
|
362 |
-
background: -moz-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
363 |
-
/* FF3.6+ */
|
364 |
-
background: -ms-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
365 |
-
/* IE10+ */
|
366 |
-
background: -o-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
367 |
-
/* Opera 11.10+ */
|
368 |
-
background: linear-gradient(to bottom, #2b2b2b 0%, #0c0c0c 100%);
|
369 |
-
/* W3C */
|
370 |
-
box-shadow: inset 0 0 3px #111;
|
371 |
-
}
|
372 |
-
.dataTables_wrapper .dataTables_paginate .ellipsis {
|
373 |
-
padding: 0 1em;
|
374 |
-
}
|
375 |
-
.dataTables_wrapper .dataTables_processing {
|
376 |
-
position: absolute;
|
377 |
-
top: 50%;
|
378 |
-
left: 50%;
|
379 |
-
width: 100%;
|
380 |
-
height: 40px;
|
381 |
-
margin-left: -50%;
|
382 |
-
margin-top: -25px;
|
383 |
-
padding-top: 20px;
|
384 |
-
text-align: center;
|
385 |
-
font-size: 1.2em;
|
386 |
-
background-color: white;
|
387 |
-
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0)), color-stop(25%, rgba(255, 255, 255, 0.9)), color-stop(75%, rgba(255, 255, 255, 0.9)), color-stop(100%, rgba(255, 255, 255, 0)));
|
388 |
-
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
389 |
-
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
390 |
-
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
391 |
-
background: -o-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
392 |
-
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
393 |
-
}
|
394 |
-
.dataTables_wrapper .dataTables_length,
|
395 |
-
.dataTables_wrapper .dataTables_filter,
|
396 |
-
.dataTables_wrapper .dataTables_info,
|
397 |
-
.dataTables_wrapper .dataTables_processing,
|
398 |
-
.dataTables_wrapper .dataTables_paginate {
|
399 |
-
color: #333;
|
400 |
-
}
|
401 |
-
.dataTables_wrapper .dataTables_scroll {
|
402 |
-
clear: both;
|
403 |
-
}
|
404 |
-
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody {
|
405 |
-
*margin-top: -1px;
|
406 |
-
-webkit-overflow-scrolling: touch;
|
407 |
-
}
|
408 |
-
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th, .dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td {
|
409 |
-
vertical-align: middle;
|
410 |
-
}
|
411 |
-
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th > div.dataTables_sizing,
|
412 |
-
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td > div.dataTables_sizing {
|
413 |
-
height: 0;
|
414 |
-
overflow: hidden;
|
415 |
-
margin: 0 !important;
|
416 |
-
padding: 0 !important;
|
417 |
-
}
|
418 |
-
.dataTables_wrapper.no-footer .dataTables_scrollBody {
|
419 |
-
border-bottom: 1px solid #111;
|
420 |
-
}
|
421 |
-
.dataTables_wrapper.no-footer div.dataTables_scrollHead table,
|
422 |
-
.dataTables_wrapper.no-footer div.dataTables_scrollBody table {
|
423 |
-
border-bottom: none;
|
424 |
-
}
|
425 |
-
.dataTables_wrapper:after {
|
426 |
-
visibility: hidden;
|
427 |
-
display: block;
|
428 |
-
content: "";
|
429 |
-
clear: both;
|
430 |
-
height: 0;
|
431 |
-
}
|
432 |
-
|
433 |
-
@media screen and (max-width: 767px) {
|
434 |
-
.dataTables_wrapper .dataTables_info,
|
435 |
-
.dataTables_wrapper .dataTables_paginate {
|
436 |
-
float: none;
|
437 |
-
text-align: center;
|
438 |
-
}
|
439 |
-
.dataTables_wrapper .dataTables_paginate {
|
440 |
-
margin-top: 0.5em;
|
441 |
-
}
|
442 |
-
}
|
443 |
-
@media screen and (max-width: 640px) {
|
444 |
-
.dataTables_wrapper .dataTables_length,
|
445 |
-
.dataTables_wrapper .dataTables_filter {
|
446 |
-
float: none;
|
447 |
-
text-align: center;
|
448 |
-
}
|
449 |
-
.dataTables_wrapper .dataTables_filter {
|
450 |
-
margin-top: 0.5em;
|
451 |
-
}
|
452 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
common/vendor/datatables/media/css/jquery.dataTables.min.css
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
table.dataTable{width:100%;margin:0 auto;clear:both;border-collapse:separate;border-spacing:0}table.dataTable thead th,table.dataTable tfoot th{font-weight:bold}table.dataTable thead th,table.dataTable thead td{padding:10px 18px;border-bottom:1px solid #111}table.dataTable thead th:active,table.dataTable thead td:active{outline:none}table.dataTable tfoot th,table.dataTable tfoot td{padding:10px 18px 6px 18px;border-top:1px solid #111}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_desc{cursor:pointer;*cursor:hand}table.dataTable thead .sorting,table.dataTable thead .sorting_asc,table.dataTable thead .sorting_desc,table.dataTable thead .sorting_asc_disabled,table.dataTable thead .sorting_desc_disabled{background-repeat:no-repeat;background-position:center right}table.dataTable thead .sorting{background-image:url("../images/sort_both.png")}table.dataTable thead .sorting_asc{background-image:url("../images/sort_asc.png")}table.dataTable thead .sorting_desc{background-image:url("../images/sort_desc.png")}table.dataTable thead .sorting_asc_disabled{background-image:url("../images/sort_asc_disabled.png")}table.dataTable thead .sorting_desc_disabled{background-image:url("../images/sort_desc_disabled.png")}table.dataTable tbody tr{background-color:#ffffff}table.dataTable tbody tr.selected{background-color:#B0BED9}table.dataTable tbody th,table.dataTable tbody td{padding:8px 10px}table.dataTable.row-border tbody th,table.dataTable.row-border tbody td,table.dataTable.display tbody th,table.dataTable.display tbody td{border-top:1px solid #ddd}table.dataTable.row-border tbody tr:first-child th,table.dataTable.row-border tbody tr:first-child td,table.dataTable.display tbody tr:first-child th,table.dataTable.display tbody tr:first-child td{border-top:none}table.dataTable.cell-border tbody th,table.dataTable.cell-border tbody td{border-top:1px solid #ddd;border-right:1px solid #ddd}table.dataTable.cell-border tbody tr th:first-child,table.dataTable.cell-border tbody tr td:first-child{border-left:1px solid #ddd}table.dataTable.cell-border tbody tr:first-child th,table.dataTable.cell-border tbody tr:first-child td{border-top:none}table.dataTable.stripe tbody tr.odd,table.dataTable.display tbody tr.odd{background-color:#f9f9f9}table.dataTable.stripe tbody tr.odd.selected,table.dataTable.display tbody tr.odd.selected{background-color:#acbad4}table.dataTable.hover tbody tr:hover,table.dataTable.display tbody tr:hover{background-color:#f6f6f6}table.dataTable.hover tbody tr:hover.selected,table.dataTable.display tbody tr:hover.selected{background-color:#aab7d1}table.dataTable.order-column tbody tr>.sorting_1,table.dataTable.order-column tbody tr>.sorting_2,table.dataTable.order-column tbody tr>.sorting_3,table.dataTable.display tbody tr>.sorting_1,table.dataTable.display tbody tr>.sorting_2,table.dataTable.display tbody tr>.sorting_3{background-color:#fafafa}table.dataTable.order-column tbody tr.selected>.sorting_1,table.dataTable.order-column tbody tr.selected>.sorting_2,table.dataTable.order-column tbody tr.selected>.sorting_3,table.dataTable.display tbody tr.selected>.sorting_1,table.dataTable.display tbody tr.selected>.sorting_2,table.dataTable.display tbody tr.selected>.sorting_3{background-color:#acbad5}table.dataTable.display tbody tr.odd>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd>.sorting_1{background-color:#f1f1f1}table.dataTable.display tbody tr.odd>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd>.sorting_2{background-color:#f3f3f3}table.dataTable.display tbody tr.odd>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd>.sorting_3{background-color:whitesmoke}table.dataTable.display tbody tr.odd.selected>.sorting_1,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_1{background-color:#a6b4cd}table.dataTable.display tbody tr.odd.selected>.sorting_2,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_2{background-color:#a8b5cf}table.dataTable.display tbody tr.odd.selected>.sorting_3,table.dataTable.order-column.stripe tbody tr.odd.selected>.sorting_3{background-color:#a9b7d1}table.dataTable.display tbody tr.even>.sorting_1,table.dataTable.order-column.stripe tbody tr.even>.sorting_1{background-color:#fafafa}table.dataTable.display tbody tr.even>.sorting_2,table.dataTable.order-column.stripe tbody tr.even>.sorting_2{background-color:#fcfcfc}table.dataTable.display tbody tr.even>.sorting_3,table.dataTable.order-column.stripe tbody tr.even>.sorting_3{background-color:#fefefe}table.dataTable.display tbody tr.even.selected>.sorting_1,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_1{background-color:#acbad5}table.dataTable.display tbody tr.even.selected>.sorting_2,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_2{background-color:#aebcd6}table.dataTable.display tbody tr.even.selected>.sorting_3,table.dataTable.order-column.stripe tbody tr.even.selected>.sorting_3{background-color:#afbdd8}table.dataTable.display tbody tr:hover>.sorting_1,table.dataTable.order-column.hover tbody tr:hover>.sorting_1{background-color:#eaeaea}table.dataTable.display tbody tr:hover>.sorting_2,table.dataTable.order-column.hover tbody tr:hover>.sorting_2{background-color:#ececec}table.dataTable.display tbody tr:hover>.sorting_3,table.dataTable.order-column.hover tbody tr:hover>.sorting_3{background-color:#efefef}table.dataTable.display tbody tr:hover.selected>.sorting_1,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_1{background-color:#a2aec7}table.dataTable.display tbody tr:hover.selected>.sorting_2,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_2{background-color:#a3b0c9}table.dataTable.display tbody tr:hover.selected>.sorting_3,table.dataTable.order-column.hover tbody tr:hover.selected>.sorting_3{background-color:#a5b2cb}table.dataTable.no-footer{border-bottom:1px solid #111}table.dataTable.nowrap th,table.dataTable.nowrap td{white-space:nowrap}table.dataTable.compact thead th,table.dataTable.compact thead td{padding:4px 17px 4px 4px}table.dataTable.compact tfoot th,table.dataTable.compact tfoot td{padding:4px}table.dataTable.compact tbody th,table.dataTable.compact tbody td{padding:4px}table.dataTable th.dt-left,table.dataTable td.dt-left{text-align:left}table.dataTable th.dt-center,table.dataTable td.dt-center,table.dataTable td.dataTables_empty{text-align:center}table.dataTable th.dt-right,table.dataTable td.dt-right{text-align:right}table.dataTable th.dt-justify,table.dataTable td.dt-justify{text-align:justify}table.dataTable th.dt-nowrap,table.dataTable td.dt-nowrap{white-space:nowrap}table.dataTable thead th.dt-head-left,table.dataTable thead td.dt-head-left,table.dataTable tfoot th.dt-head-left,table.dataTable tfoot td.dt-head-left{text-align:left}table.dataTable thead th.dt-head-center,table.dataTable thead td.dt-head-center,table.dataTable tfoot th.dt-head-center,table.dataTable tfoot td.dt-head-center{text-align:center}table.dataTable thead th.dt-head-right,table.dataTable thead td.dt-head-right,table.dataTable tfoot th.dt-head-right,table.dataTable tfoot td.dt-head-right{text-align:right}table.dataTable thead th.dt-head-justify,table.dataTable thead td.dt-head-justify,table.dataTable tfoot th.dt-head-justify,table.dataTable tfoot td.dt-head-justify{text-align:justify}table.dataTable thead th.dt-head-nowrap,table.dataTable thead td.dt-head-nowrap,table.dataTable tfoot th.dt-head-nowrap,table.dataTable tfoot td.dt-head-nowrap{white-space:nowrap}table.dataTable tbody th.dt-body-left,table.dataTable tbody td.dt-body-left{text-align:left}table.dataTable tbody th.dt-body-center,table.dataTable tbody td.dt-body-center{text-align:center}table.dataTable tbody th.dt-body-right,table.dataTable tbody td.dt-body-right{text-align:right}table.dataTable tbody th.dt-body-justify,table.dataTable tbody td.dt-body-justify{text-align:justify}table.dataTable tbody th.dt-body-nowrap,table.dataTable tbody td.dt-body-nowrap{white-space:nowrap}table.dataTable,table.dataTable th,table.dataTable td{-webkit-box-sizing:content-box;box-sizing:content-box}.dataTables_wrapper{position:relative;clear:both;*zoom:1;zoom:1}.dataTables_wrapper .dataTables_length{float:left}.dataTables_wrapper .dataTables_filter{float:right;text-align:right}.dataTables_wrapper .dataTables_filter input{margin-left:0.5em}.dataTables_wrapper .dataTables_info{clear:both;float:left;padding-top:0.755em}.dataTables_wrapper .dataTables_paginate{float:right;text-align:right;padding-top:0.25em}.dataTables_wrapper .dataTables_paginate .paginate_button{box-sizing:border-box;display:inline-block;min-width:1.5em;padding:0.5em 1em;margin-left:2px;text-align:center;text-decoration:none !important;cursor:pointer;*cursor:hand;color:#333 !important;border:1px solid transparent;border-radius:2px}.dataTables_wrapper .dataTables_paginate .paginate_button.current,.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover{color:#333 !important;border:1px solid #979797;background-color:white;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #fff), color-stop(100%, #dcdcdc));background:-webkit-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-moz-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-ms-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:-o-linear-gradient(top, #fff 0%, #dcdcdc 100%);background:linear-gradient(to bottom, #fff 0%, #dcdcdc 100%)}.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover,.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active{cursor:default;color:#666 !important;border:1px solid transparent;background:transparent;box-shadow:none}.dataTables_wrapper .dataTables_paginate .paginate_button:hover{color:white !important;border:1px solid #111;background-color:#585858;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #585858), color-stop(100%, #111));background:-webkit-linear-gradient(top, #585858 0%, #111 100%);background:-moz-linear-gradient(top, #585858 0%, #111 100%);background:-ms-linear-gradient(top, #585858 0%, #111 100%);background:-o-linear-gradient(top, #585858 0%, #111 100%);background:linear-gradient(to bottom, #585858 0%, #111 100%)}.dataTables_wrapper .dataTables_paginate .paginate_button:active{outline:none;background-color:#2b2b2b;background:-webkit-gradient(linear, left top, left bottom, color-stop(0%, #2b2b2b), color-stop(100%, #0c0c0c));background:-webkit-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-moz-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-ms-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:-o-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);background:linear-gradient(to bottom, #2b2b2b 0%, #0c0c0c 100%);box-shadow:inset 0 0 3px #111}.dataTables_wrapper .dataTables_paginate .ellipsis{padding:0 1em}.dataTables_wrapper .dataTables_processing{position:absolute;top:50%;left:50%;width:100%;height:40px;margin-left:-50%;margin-top:-25px;padding-top:20px;text-align:center;font-size:1.2em;background-color:white;background:-webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255,255,255,0)), color-stop(25%, rgba(255,255,255,0.9)), color-stop(75%, rgba(255,255,255,0.9)), color-stop(100%, rgba(255,255,255,0)));background:-webkit-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-moz-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-ms-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:-o-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%);background:linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 25%, rgba(255,255,255,0.9) 75%, rgba(255,255,255,0) 100%)}.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_filter,.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_processing,.dataTables_wrapper .dataTables_paginate{color:#333}.dataTables_wrapper .dataTables_scroll{clear:both}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody{*margin-top:-1px;-webkit-overflow-scrolling:touch}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td{vertical-align:middle}.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th>div.dataTables_sizing,.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td>div.dataTables_sizing{height:0;overflow:hidden;margin:0 !important;padding:0 !important}.dataTables_wrapper.no-footer .dataTables_scrollBody{border-bottom:1px solid #111}.dataTables_wrapper.no-footer div.dataTables_scrollHead table,.dataTables_wrapper.no-footer div.dataTables_scrollBody table{border-bottom:none}.dataTables_wrapper:after{visibility:hidden;display:block;content:"";clear:both;height:0}@media screen and (max-width: 767px){.dataTables_wrapper .dataTables_info,.dataTables_wrapper .dataTables_paginate{float:none;text-align:center}.dataTables_wrapper .dataTables_paginate{margin-top:0.5em}}@media screen and (max-width: 640px){.dataTables_wrapper .dataTables_length,.dataTables_wrapper .dataTables_filter{float:none;text-align:center}.dataTables_wrapper .dataTables_filter{margin-top:0.5em}}
|
|
common/vendor/datatables/media/css/jquery.dataTables_themeroller.css
DELETED
@@ -1,416 +0,0 @@
|
|
1 |
-
/*
|
2 |
-
* Table styles
|
3 |
-
*/
|
4 |
-
table.dataTable {
|
5 |
-
width: 100%;
|
6 |
-
margin: 0 auto;
|
7 |
-
clear: both;
|
8 |
-
border-collapse: separate;
|
9 |
-
border-spacing: 0;
|
10 |
-
/*
|
11 |
-
* Header and footer styles
|
12 |
-
*/
|
13 |
-
/*
|
14 |
-
* Body styles
|
15 |
-
*/
|
16 |
-
}
|
17 |
-
table.dataTable thead th,
|
18 |
-
table.dataTable thead td,
|
19 |
-
table.dataTable tfoot th,
|
20 |
-
table.dataTable tfoot td {
|
21 |
-
padding: 4px 10px;
|
22 |
-
}
|
23 |
-
table.dataTable thead th,
|
24 |
-
table.dataTable tfoot th {
|
25 |
-
font-weight: bold;
|
26 |
-
}
|
27 |
-
table.dataTable thead th:active,
|
28 |
-
table.dataTable thead td:active {
|
29 |
-
outline: none;
|
30 |
-
}
|
31 |
-
table.dataTable thead .sorting_asc,
|
32 |
-
table.dataTable thead .sorting_desc,
|
33 |
-
table.dataTable thead .sorting {
|
34 |
-
cursor: pointer;
|
35 |
-
*cursor: hand;
|
36 |
-
}
|
37 |
-
table.dataTable thead th div.DataTables_sort_wrapper {
|
38 |
-
position: relative;
|
39 |
-
padding-right: 10px;
|
40 |
-
}
|
41 |
-
table.dataTable thead th div.DataTables_sort_wrapper span {
|
42 |
-
position: absolute;
|
43 |
-
top: 50%;
|
44 |
-
margin-top: -8px;
|
45 |
-
right: -5px;
|
46 |
-
}
|
47 |
-
table.dataTable thead th.ui-state-default {
|
48 |
-
border-right-width: 0;
|
49 |
-
}
|
50 |
-
table.dataTable thead th.ui-state-default:last-child {
|
51 |
-
border-right-width: 1px;
|
52 |
-
}
|
53 |
-
table.dataTable tbody tr {
|
54 |
-
background-color: #ffffff;
|
55 |
-
}
|
56 |
-
table.dataTable tbody tr.selected {
|
57 |
-
background-color: #B0BED9;
|
58 |
-
}
|
59 |
-
table.dataTable tbody th,
|
60 |
-
table.dataTable tbody td {
|
61 |
-
padding: 8px 10px;
|
62 |
-
}
|
63 |
-
table.dataTable th.center,
|
64 |
-
table.dataTable td.center,
|
65 |
-
table.dataTable td.dataTables_empty {
|
66 |
-
text-align: center;
|
67 |
-
}
|
68 |
-
table.dataTable th.right,
|
69 |
-
table.dataTable td.right {
|
70 |
-
text-align: right;
|
71 |
-
}
|
72 |
-
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
73 |
-
border-top: 1px solid #ddd;
|
74 |
-
}
|
75 |
-
table.dataTable.row-border tbody tr:first-child th,
|
76 |
-
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
77 |
-
table.dataTable.display tbody tr:first-child td {
|
78 |
-
border-top: none;
|
79 |
-
}
|
80 |
-
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
81 |
-
border-top: 1px solid #ddd;
|
82 |
-
border-right: 1px solid #ddd;
|
83 |
-
}
|
84 |
-
table.dataTable.cell-border tbody tr th:first-child,
|
85 |
-
table.dataTable.cell-border tbody tr td:first-child {
|
86 |
-
border-left: 1px solid #ddd;
|
87 |
-
}
|
88 |
-
table.dataTable.cell-border tbody tr:first-child th,
|
89 |
-
table.dataTable.cell-border tbody tr:first-child td {
|
90 |
-
border-top: none;
|
91 |
-
}
|
92 |
-
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
93 |
-
background-color: #f9f9f9;
|
94 |
-
}
|
95 |
-
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
96 |
-
background-color: #abb9d3;
|
97 |
-
}
|
98 |
-
table.dataTable.hover tbody tr:hover,
|
99 |
-
table.dataTable.hover tbody tr.odd:hover,
|
100 |
-
table.dataTable.hover tbody tr.even:hover, table.dataTable.display tbody tr:hover,
|
101 |
-
table.dataTable.display tbody tr.odd:hover,
|
102 |
-
table.dataTable.display tbody tr.even:hover {
|
103 |
-
background-color: whitesmoke;
|
104 |
-
}
|
105 |
-
table.dataTable.hover tbody tr:hover.selected,
|
106 |
-
table.dataTable.hover tbody tr.odd:hover.selected,
|
107 |
-
table.dataTable.hover tbody tr.even:hover.selected, table.dataTable.display tbody tr:hover.selected,
|
108 |
-
table.dataTable.display tbody tr.odd:hover.selected,
|
109 |
-
table.dataTable.display tbody tr.even:hover.selected {
|
110 |
-
background-color: #a9b7d1;
|
111 |
-
}
|
112 |
-
table.dataTable.order-column tbody tr > .sorting_1,
|
113 |
-
table.dataTable.order-column tbody tr > .sorting_2,
|
114 |
-
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
115 |
-
table.dataTable.display tbody tr > .sorting_2,
|
116 |
-
table.dataTable.display tbody tr > .sorting_3 {
|
117 |
-
background-color: #f9f9f9;
|
118 |
-
}
|
119 |
-
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
120 |
-
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
121 |
-
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
122 |
-
table.dataTable.display tbody tr.selected > .sorting_2,
|
123 |
-
table.dataTable.display tbody tr.selected > .sorting_3 {
|
124 |
-
background-color: #acbad4;
|
125 |
-
}
|
126 |
-
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
127 |
-
background-color: #f1f1f1;
|
128 |
-
}
|
129 |
-
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
130 |
-
background-color: #f3f3f3;
|
131 |
-
}
|
132 |
-
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
133 |
-
background-color: whitesmoke;
|
134 |
-
}
|
135 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
136 |
-
background-color: #a6b3cd;
|
137 |
-
}
|
138 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
139 |
-
background-color: #a7b5ce;
|
140 |
-
}
|
141 |
-
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
142 |
-
background-color: #a9b6d0;
|
143 |
-
}
|
144 |
-
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
145 |
-
background-color: #f9f9f9;
|
146 |
-
}
|
147 |
-
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
148 |
-
background-color: #fbfbfb;
|
149 |
-
}
|
150 |
-
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
151 |
-
background-color: #fdfdfd;
|
152 |
-
}
|
153 |
-
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
154 |
-
background-color: #acbad4;
|
155 |
-
}
|
156 |
-
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
157 |
-
background-color: #adbbd6;
|
158 |
-
}
|
159 |
-
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
160 |
-
background-color: #afbdd8;
|
161 |
-
}
|
162 |
-
table.dataTable.display tbody tr:hover > .sorting_1,
|
163 |
-
table.dataTable.display tbody tr.odd:hover > .sorting_1,
|
164 |
-
table.dataTable.display tbody tr.even:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1,
|
165 |
-
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_1,
|
166 |
-
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_1 {
|
167 |
-
background-color: #eaeaea;
|
168 |
-
}
|
169 |
-
table.dataTable.display tbody tr:hover > .sorting_2,
|
170 |
-
table.dataTable.display tbody tr.odd:hover > .sorting_2,
|
171 |
-
table.dataTable.display tbody tr.even:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2,
|
172 |
-
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_2,
|
173 |
-
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_2 {
|
174 |
-
background-color: #ebebeb;
|
175 |
-
}
|
176 |
-
table.dataTable.display tbody tr:hover > .sorting_3,
|
177 |
-
table.dataTable.display tbody tr.odd:hover > .sorting_3,
|
178 |
-
table.dataTable.display tbody tr.even:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3,
|
179 |
-
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_3,
|
180 |
-
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_3 {
|
181 |
-
background-color: #eeeeee;
|
182 |
-
}
|
183 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_1,
|
184 |
-
table.dataTable.display tbody tr.odd:hover.selected > .sorting_1,
|
185 |
-
table.dataTable.display tbody tr.even:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1,
|
186 |
-
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_1,
|
187 |
-
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_1 {
|
188 |
-
background-color: #a1aec7;
|
189 |
-
}
|
190 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_2,
|
191 |
-
table.dataTable.display tbody tr.odd:hover.selected > .sorting_2,
|
192 |
-
table.dataTable.display tbody tr.even:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2,
|
193 |
-
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_2,
|
194 |
-
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_2 {
|
195 |
-
background-color: #a2afc8;
|
196 |
-
}
|
197 |
-
table.dataTable.display tbody tr:hover.selected > .sorting_3,
|
198 |
-
table.dataTable.display tbody tr.odd:hover.selected > .sorting_3,
|
199 |
-
table.dataTable.display tbody tr.even:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3,
|
200 |
-
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_3,
|
201 |
-
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_3 {
|
202 |
-
background-color: #a4b2cb;
|
203 |
-
}
|
204 |
-
table.dataTable.nowrap th, table.dataTable.nowrap td {
|
205 |
-
white-space: nowrap;
|
206 |
-
}
|
207 |
-
table.dataTable.compact thead th,
|
208 |
-
table.dataTable.compact thead td {
|
209 |
-
padding: 5px 9px;
|
210 |
-
}
|
211 |
-
table.dataTable.compact tfoot th,
|
212 |
-
table.dataTable.compact tfoot td {
|
213 |
-
padding: 5px 9px 3px 9px;
|
214 |
-
}
|
215 |
-
table.dataTable.compact tbody th,
|
216 |
-
table.dataTable.compact tbody td {
|
217 |
-
padding: 4px 5px;
|
218 |
-
}
|
219 |
-
table.dataTable th.dt-left,
|
220 |
-
table.dataTable td.dt-left {
|
221 |
-
text-align: left;
|
222 |
-
}
|
223 |
-
table.dataTable th.dt-center,
|
224 |
-
table.dataTable td.dt-center,
|
225 |
-
table.dataTable td.dataTables_empty {
|
226 |
-
text-align: center;
|
227 |
-
}
|
228 |
-
table.dataTable th.dt-right,
|
229 |
-
table.dataTable td.dt-right {
|
230 |
-
text-align: right;
|
231 |
-
}
|
232 |
-
table.dataTable th.dt-justify,
|
233 |
-
table.dataTable td.dt-justify {
|
234 |
-
text-align: justify;
|
235 |
-
}
|
236 |
-
table.dataTable th.dt-nowrap,
|
237 |
-
table.dataTable td.dt-n
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|