table_setter 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (103) hide show
  1. data/.document +5 -0
  2. data/.gitignore +20 -0
  3. data/LICENSE +20 -0
  4. data/README +10 -0
  5. data/Rakefile +66 -0
  6. data/TODO +3 -0
  7. data/VERSION.yml +5 -0
  8. data/bin/table-setter +5 -0
  9. data/doc/TableFu/Formatting.html +178 -0
  10. data/doc/TableSetter/App.html +176 -0
  11. data/doc/TableSetter/Command.html +376 -0
  12. data/doc/TableSetter/Table.html +1813 -0
  13. data/doc/TableSetter.html +292 -0
  14. data/doc/_index.html +146 -0
  15. data/doc/class_list.html +36 -0
  16. data/doc/css/common.css +1 -0
  17. data/doc/css/full_list.css +50 -0
  18. data/doc/css/style.css +268 -0
  19. data/doc/file.README.html +68 -0
  20. data/doc/file_list.html +38 -0
  21. data/doc/frames.html +13 -0
  22. data/doc/index.html +68 -0
  23. data/doc/js/app.js +99 -0
  24. data/doc/js/full_list.js +106 -0
  25. data/doc/js/jquery.js +19 -0
  26. data/doc/method_list.html +291 -0
  27. data/doc/top-level-namespace.html +85 -0
  28. data/documentation/css/dawn.css +121 -0
  29. data/documentation/css/styles.css +63 -0
  30. data/documentation/images/folder.png +0 -0
  31. data/documentation/images/key.png +0 -0
  32. data/documentation/images/proplogo.png +0 -0
  33. data/documentation/images/publish.png +0 -0
  34. data/documentation/images/text-x-generic.png +0 -0
  35. data/documentation/index.html.erb +221 -0
  36. data/documentation/tables/example/index.html +4074 -0
  37. data/documentation/tables/example_faceted/index.html +17239 -0
  38. data/documentation/tables/example_formatted/index.html +861 -0
  39. data/documentation/tables/example_local/1/index.html +6084 -0
  40. data/documentation/tables/example_local/10/index.html +6084 -0
  41. data/documentation/tables/example_local/11/index.html +6084 -0
  42. data/documentation/tables/example_local/12/index.html +6084 -0
  43. data/documentation/tables/example_local/13/index.html +6084 -0
  44. data/documentation/tables/example_local/14/index.html +6084 -0
  45. data/documentation/tables/example_local/15/index.html +6084 -0
  46. data/documentation/tables/example_local/16/index.html +6084 -0
  47. data/documentation/tables/example_local/17/index.html +6084 -0
  48. data/documentation/tables/example_local/18/index.html +6084 -0
  49. data/documentation/tables/example_local/19/index.html +6084 -0
  50. data/documentation/tables/example_local/2/index.html +6084 -0
  51. data/documentation/tables/example_local/20/index.html +6084 -0
  52. data/documentation/tables/example_local/21/index.html +6084 -0
  53. data/documentation/tables/example_local/22/index.html +6084 -0
  54. data/documentation/tables/example_local/23/index.html +6084 -0
  55. data/documentation/tables/example_local/24/index.html +1404 -0
  56. data/documentation/tables/example_local/3/index.html +6084 -0
  57. data/documentation/tables/example_local/4/index.html +6084 -0
  58. data/documentation/tables/example_local/5/index.html +6084 -0
  59. data/documentation/tables/example_local/6/index.html +6084 -0
  60. data/documentation/tables/example_local/7/index.html +6084 -0
  61. data/documentation/tables/example_local/8/index.html +6084 -0
  62. data/documentation/tables/example_local/9/index.html +6084 -0
  63. data/documentation/tables/example_local/index.html +6084 -0
  64. data/documentation/tables/favicon.ico +0 -0
  65. data/documentation/tables/images/th_arrow_asc.gif +0 -0
  66. data/documentation/tables/images/th_arrow_desc.gif +0 -0
  67. data/documentation/tables/index.html +48 -0
  68. data/documentation/tables/javascripts/application.js +32 -0
  69. data/documentation/tables/javascripts/jquery.tablesorter.js +852 -0
  70. data/documentation/tables/javascripts/jquery.tablesorter.multipagefilter.js +111 -0
  71. data/documentation/tables/javascripts/jquery.tablesorter.pager.js +183 -0
  72. data/documentation/tables/stylesheets/stylesheet.css +67 -0
  73. data/index.html +238 -0
  74. data/lib/table_setter/app.rb +54 -0
  75. data/lib/table_setter/command.rb +139 -0
  76. data/lib/table_setter/table.rb +226 -0
  77. data/lib/table_setter.rb +32 -0
  78. data/spec/spec.opts +1 -0
  79. data/spec/spec_helper.rb +11 -0
  80. data/spec/table-setter-app_spec.rb +24 -0
  81. data/spec/table-setter_spec.rb +179 -0
  82. data/table_setter.gemspec +171 -0
  83. data/template/config.ru +33 -0
  84. data/template/public/favicon.ico +0 -0
  85. data/template/public/images/th_arrow_asc.gif +0 -0
  86. data/template/public/images/th_arrow_desc.gif +0 -0
  87. data/template/public/javascripts/application.js +32 -0
  88. data/template/public/javascripts/jquery.tablesorter.js +852 -0
  89. data/template/public/javascripts/jquery.tablesorter.multipagefilter.js +111 -0
  90. data/template/public/javascripts/jquery.tablesorter.pager.js +183 -0
  91. data/template/public/stylesheets/stylesheet.css +74 -0
  92. data/template/tables/example.yml +21 -0
  93. data/template/tables/example_faceted.yml +27 -0
  94. data/template/tables/example_formatted.csv +1 -0
  95. data/template/tables/example_formatted.yml +27 -0
  96. data/template/tables/example_local.csv +5806 -0
  97. data/template/tables/example_local.yml +27 -0
  98. data/template/views/404.erb +4 -0
  99. data/template/views/500.erb +4 -0
  100. data/template/views/index.erb +7 -0
  101. data/template/views/layout.erb +34 -0
  102. data/template/views/table.erb +78 -0
  103. metadata +240 -0
File without changes
@@ -0,0 +1,48 @@
1
+
2
+ <!DOCTYPE html>
3
+ <html>
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
6
+ <title>All Tables</title>
7
+ <script type="text/javascript"
8
+ src="http://www.google.com/jsapi"></script>
9
+ <script type="text/javascript">
10
+ google.load("jquery", "1", {uncompressed:true})
11
+ </script>
12
+ <script charset="utf-8" src="/table-setter/documentation/tables/javascripts/jquery.tablesorter.js" type="text/javascript"></script>
13
+ <script charset="utf-8" src="/table-setter/documentation/tables/javascripts/jquery.tablesorter.pager.js" type="text/javascript"></script>
14
+ <script charset="utf-8" src="/table-setter/documentation/tables/javascripts/jquery.tablesorter.multipagefilter.js" type="text/javascript"></script>
15
+ <script charset="utf-8" src="/table-setter/documentation/tables/javascripts/application.js" type="text/javascript"></script>
16
+ <link charset="utf-8" href="/table-setter/documentation/tables/stylesheets/stylesheet.css" media="screen" rel="stylesheet" type="text/css">
17
+
18
+ <script>
19
+
20
+ var sortPlease = false;
21
+
22
+ </script>
23
+
24
+ </head>
25
+ <body>
26
+ <div id="table_fu">
27
+ <ul>
28
+
29
+ <li>
30
+ <a href="/table-setter/documentation/tables/example/">Failed Banks List</a>
31
+ </li>
32
+
33
+ <li>
34
+ <a href="/table-setter/documentation/tables/example_faceted/">Appropriations by District</a>
35
+ </li>
36
+
37
+ <li>
38
+ <a href="/table-setter/documentation/tables/example_formatted/">Stimulus Progress</a>
39
+ </li>
40
+
41
+ <li>
42
+ <a href="/table-setter/documentation/tables/example_local/">Browse All Approved Stimulus Highway Projects</a>
43
+ </li>
44
+
45
+ </ul>
46
+ </div>
47
+ </body>
48
+ </html>
@@ -0,0 +1,32 @@
1
+ $(document).ready(function(){
2
+ if(!sortPlease) return;
3
+ $.tablesorter.addWidget({
4
+ id: "columnHighlight",
5
+ format: function(table) {
6
+ if (!this.tds)
7
+ this.tds = $("td", table.tBodies[0]);
8
+ if (!this.headers)
9
+ this.headers = $("thead th", table);
10
+ this.tds.removeClass("sorted");
11
+ var ascSort = $("th." + table.config.cssAsc);
12
+ var descSort = $("th." + table.config.cssDesc);
13
+ if (ascSort.length)
14
+ index = this.headers.index(ascSort[0]);
15
+ if (descSort.length)
16
+ index = this.headers.index(descSort[0]);
17
+ $("tr td:nth-child(" + (index+1) + ")", table.tBodies[0]).each(function(row){
18
+ $(this).addClass('sorted');
19
+ });
20
+ }
21
+ });
22
+
23
+ //initialize the table
24
+ var table = window.table = $('#data').tablesorter({
25
+ widgets: ['columnHighlight'],
26
+ sortList: sortOrder//,
27
+ //debug: true
28
+ })
29
+ .tablesorterPager({container: $("#pager"), positionFixed: false})
30
+ .tablesorterMultiPageFilter({filterSelector: $("#filter input")});
31
+
32
+ });